{"_id":"@amskey/mfm-js","_rev":"3-3f3329d02d4da135810627bb42306364","name":"@amskey/mfm-js","dist-tags":{"latest":"0.24.0-amskey.0"},"versions":{"0.24.0":{"name":"@amskey/mfm-js","version":"0.24.0","author":{"name":"Marihachi"},"license":"MIT","_id":"@amskey/mfm-js@0.24.0","maintainers":[{"name":"amasecocoa","email":"amase.cocoa@gmail.com"}],"homepage":"https://github.com/misskey-dev/mfm.js#readme","bugs":{"url":"https://github.com/misskey-dev/mfm.js/issues"},"dist":{"shasum":"726eb35f3f952202286ebe76f92fdeb35110317a","tarball":"https://registry.npmjs.org/@amskey/mfm-js/-/mfm-js-0.24.0.tgz","fileCount":4,"integrity":"sha512-eQMYY80ZIUwGErxLrUnfx9auEJvxOW3Kou0FqqSgbuQwTr8JNOqc0oMm0YI/pnlh3T1qeT96O8KN92M6yjignA==","signatures":[{"sig":"MEQCIGYQ5cW3WZxFZfyEtDxyirfccms3fmyCQ1ZkRFFzKIadAiB3WjaDTauS8wOfLmTnAeKjbm5/POeck0MDQ7GktyvPcQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":6144},"main":"./built/index.js","types":"./built/index.d.ts","gitHead":"35243ec8ddf58ea9f074acf1246c61f137c0bd09","scripts":{"api":"npx api-extractor run --local --verbose","tsc":"tsc","tsd":"tsd","jest":"jest --coverage","lint":"eslint . --ext .js,.jsx,.ts,.tsx","test":"npm run jest && npm run tsd","build":"npm run tsc","parse":"node ./built/cli/parse","api-prod":"npx api-extractor run --verbose","parse-simple":"node ./built/cli/parseSimple"},"_npmUser":{"name":"amasecocoa","email":"amase.cocoa@gmail.com"},"repository":{"url":"git+https://github.com/misskey-dev/mfm.js.git","type":"git"},"_npmVersion":"10.9.2","description":"An MFM parser implementation with TypeScript","directories":{},"_nodeVersion":"22.14.0","dependencies":{"@twemoji/parser":"15.0.0"},"_hasShrinkwrap":false,"devDependencies":{"tsd":"0.30.0","jest":"29.7.0","eslint":"8.56.0","ts-jest":"29.1.1","ts-node":"10.9.2","typescript":"5.3.3","@types/jest":"29.5.11","@types/node":"20.10.5","@microsoft/api-extractor":"7.38.5","@typescript-eslint/parser":"6.14.0","@typescript-eslint/eslint-plugin":"6.14.0"},"_npmOperationalInternal":{"tmp":"tmp/mfm-js_0.24.0_1742303187475_0.4715222664077061","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."},"0.24.0-amskey.0":{"name":"@amskey/mfm-js","version":"0.24.0-amskey.0","author":{"name":"Marihachi"},"license":"MIT","_id":"@amskey/mfm-js@0.24.0-amskey.0","maintainers":[{"name":"amasecocoa","email":"amase.cocoa@gmail.com"}],"homepage":"https://github.com/misskey-dev/mfm.js#readme","bugs":{"url":"https://github.com/misskey-dev/mfm.js/issues"},"dist":{"shasum":"9699cfaa1f37383fca166b1b79cb1da0cfab9eeb","tarball":"https://registry.npmjs.org/@amskey/mfm-js/-/mfm-js-0.24.0-amskey.0.tgz","fileCount":24,"integrity":"sha512-sdsxstx2FuOJELlprePHxl5ZkmT7tAk0QxjxzwBea0rQNWXZmUkm8ngPgVUILgtSWXrCAUEHJSAcXZ0e/Sq0Kg==","signatures":[{"sig":"MEUCIQCODc+SCpt/LoBpgDbyGqueEzjOZira/iqQFC1UGhsiBQIgdHewcDNBq4zIB1qhlSdw6UjQ3Wo66ioC7JEq7+IKTSY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":64931},"main":"./built/index.js","types":"./built/index.d.ts","gitHead":"35243ec8ddf58ea9f074acf1246c61f137c0bd09","scripts":{"api":"npx api-extractor run --local --verbose","tsc":"tsc","tsd":"tsd","jest":"jest --coverage","lint":"eslint . --ext .js,.jsx,.ts,.tsx","test":"npm run jest && npm run tsd","build":"npm run tsc","parse":"node ./built/cli/parse","api-prod":"npx api-extractor run --verbose","parse-simple":"node ./built/cli/parseSimple"},"_npmUser":{"name":"amasecocoa","email":"amase.cocoa@gmail.com"},"repository":{"url":"git+https://github.com/misskey-dev/mfm.js.git","type":"git"},"_npmVersion":"10.9.2","description":"An MFM parser implementation with TypeScript (fork)","directories":{},"_nodeVersion":"22.14.0","dependencies":{"@twemoji/parser":"15.0.0"},"_hasShrinkwrap":false,"devDependencies":{"tsd":"0.30.0","jest":"29.7.0","eslint":"8.56.0","ts-jest":"29.1.1","ts-node":"10.9.2","typescript":"5.3.3","@types/jest":"29.5.11","@types/node":"20.10.5","@microsoft/api-extractor":"7.38.5","@typescript-eslint/parser":"6.14.0","@typescript-eslint/eslint-plugin":"6.14.0"},"_npmOperationalInternal":{"tmp":"tmp/mfm-js_0.24.0-amskey.0_1742303655539_0.5526464614666289","host":"s3://npm-registry-packages-npm-production"},"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info."}},"time":{"created":"2025-03-18T13:06:27.396Z","modified":"2025-11-30T09:39:07.317Z","0.24.0":"2025-03-18T13:06:27.666Z","0.24.0-amskey.0":"2025-03-18T13:14:15.741Z"},"bugs":{"url":"https://github.com/misskey-dev/mfm.js/issues"},"author":{"name":"Marihachi"},"license":"MIT","homepage":"https://github.com/misskey-dev/mfm.js#readme","repository":{"url":"git+https://github.com/misskey-dev/mfm.js.git","type":"git"},"description":"An MFM parser implementation with TypeScript (fork)","maintainers":[{"name":"amasecocoa","email":"amase.cocoa@gmail.com"}],"readme":"# mfm.js\r\nAn MFM parser implementation with TypeScript.\r\n[Try it out!](https://runkit.com/npm/mfm-js)\r\n\r\n[![Test](https://github.com/misskey-dev/mfm.js/actions/workflows/test.yml/badge.svg)](https://github.com/misskey-dev/mfm.js/actions/workflows/test.yml)\r\n[![codecov](https://codecov.io/gh/misskey-dev/mfm.js/branch/develop/graph/badge.svg?token=irAWFiHK8T)](https://codecov.io/gh/misskey-dev/mfm.js)\r\n\r\n[![NPM](https://nodei.co/npm/mfm-js.png?downloads=true&downloadRank=true&stars=true)](https://www.npmjs.com/package/mfm-js)\r\n\r\n## Installation\r\n```\r\nnpm i mfm-js\r\n```\r\n\r\n## Usage\r\nPlease see [docs](./docs/index.md) for the detail.\r\n\r\nTypeScript:\r\n```ts\r\nimport * as mfm from 'mfm-js';\r\n\r\nconst inputText =\r\n`<center>\r\nHello $[tada everynyan! 🎉]\r\n\r\nI'm @ai, A bot of misskey!\r\n\r\nhttps://github.com/syuilo/ai\r\n</center>`;\r\n\r\n// Generate a MFM tree from the full MFM text.\r\nconst mfmTree = mfm.parse(inputText);\r\n\r\n// Generate a MFM tree from the simple MFM text.\r\nconst simpleMfmTree = mfm.parseSimple('I like the hot soup :soup:​');\r\n\r\n// Reverse to a MFM text from the MFM tree.\r\nconst text = mfm.toString(mfmTree);\r\n\r\n```\r\n\r\n## Develop\r\n### 1. Clone\r\n```\r\ngit clone https://github.com/misskey-dev/mfm.js.git\r\n```\r\n\r\n### 2. Install packages\r\n```\r\ncd mfm.js\r\nnpm i\r\n```\r\n\r\n### 3. Build\r\n```\r\nnpm run build\r\n```\r\n\r\n### Use the interactive CLI parser\r\nfull parser:\r\n```\r\nnpm run parse\r\n```\r\n\r\nsimple parser:\r\n```\r\nnpm run parse-simple\r\n```\r\n\r\n## License\r\nThis software is released under the [MIT License](LICENSE).\r\n","readmeFilename":"README.md"}