{"id":20388,"library":"prettier-plugin-md-nocjsp","title":"Prettier Plugin Markdown No CJK Space","description":"A Prettier plugin (v1.5.1, active) that prevents Prettier from inserting spaces between Chinese/Japanese characters and Latin letters/numbers in Markdown documents. Requires Prettier 2.x. Not needed with Prettier 3.x. Provides custom parsers 'markdown-nocjsp' and 'mdx-nocjsp'. Key differentiator: solves the specific issue of unwanted spacing for CJK text, with a quickFix option to revert past damage.","status":"active","version":"1.5.1","language":"javascript","source_language":"en","source_url":"https://github.com/tats-u/prettier-plugin-md-nocjsp","tags":["javascript","prettier","plugin","markdown","japanese"],"install":[{"cmd":"npm install prettier-plugin-md-nocjsp","lang":"bash","label":"npm"},{"cmd":"yarn add prettier-plugin-md-nocjsp","lang":"bash","label":"yarn"},{"cmd":"pnpm add prettier-plugin-md-nocjsp","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency: required to run as a plugin","package":"prettier","optional":false}],"imports":[{"note":"Installed as a Prettier plugin, not imported directly in code. Use via CLI or config.","wrong":"import prettierPluginMdNocjsp from 'prettier-plugin-md-nocjsp'; // not a JS module, it's a plugin","symbol":"plugin","correct":"Add 'prettier-plugin-md-nocjsp' to package.json or .prettierrc plugins; no JavaScript import needed"},{"note":"Available parsers: markdown-nocjsp (for .md) and mdx-nocjsp (for .mdx).","wrong":"parser: 'nocjsp' // incorrect name","symbol":"parser","correct":"Set parser: 'markdown-nocjsp' in .prettierrc overrides"},{"note":"quickFix is a private option available since v1.4.0, not exposed via CLI.","wrong":"quickFix: false // default is false, but setting true only for one-time fix","symbol":"option","correct":"Set quickFix: true in .prettierrc overrides to remove existing extra spaces"}],"quickstart":{"code":"// Install dependencies\nnpm install --save-dev prettier prettier-plugin-md-nocjsp\n\n// Create .prettierrc with:\n{\n  \"overrides\": [\n    {\n      \"files\": [\"*.md\", \"README\"],\n      \"options\": {\n        \"parser\": \"markdown-nocjsp\"\n      }\n    },\n    {\n      \"files\": \"*.mdx\",\n      \"options\": {\n        \"parser\": \"mdx-nocjsp\"\n      }\n    }\n  ]\n}\n\n// Format your Markdown files\nnpx prettier --write *.md","lang":"javascript","description":"Shows installation, configuration with overrides for .md and .mdx, and formatting via CLI."},"warnings":[{"fix":"Uninstall this plugin when upgrading to Prettier 3.x; it is no longer needed.","message":"This plugin will NOT work with Prettier 3.x. Use the built-in behavior instead.","severity":"breaking","affected_versions":">=1.0.0"},{"fix":"Switch to Prettier 3.x and remove this plugin from dependencies.","message":"The functionality has been merged into Prettier 3.x. This plugin is deprecated for future use.","severity":"deprecated","affected_versions":">=1.0.0"},{"fix":"Add quickFix: true to .prettierrc overrides section for a one-time format.","message":"quickFix option only works in configuration file, not via CLI flags.","severity":"gotcha","affected_versions":">=1.4.0"},{"fix":"Use the plugin only for CJK spacing; configure other Prettier options separately.","message":"The plugin only affects Markdown parsing; other Prettier rules (e.g., wrapping) still apply.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Ensure the package is installed and Prettier can find it (e.g., install in project root or use --plugins).","message":"The plugin must be listed as a plugin in Prettier config or discovered automatically; it is not imported as a module.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Run npm install --save-dev prettier-plugin-md-nocjsp","cause":"Plugin not installed or not in node_modules","error":"Cannot find module 'prettier-plugin-md-nocjsp'"},{"fix":"Install the plugin and ensure it is listed in plugins or auto-discovered","cause":"Prettier cannot load the plugin; it may be missing or not installed","error":"Unsupported parser \"markdown-nocjsp\" specified. This typically indicates a misconfigured plugin."},{"fix":"Set quickFix: true in .prettierrc overrides, not as a CLI argument","cause":"Using quickFix via CLI instead of config file","error":"Error: Unknown option: quickFix"},{"fix":"Downgrade to Prettier 2.x or uninstall this plugin (feature built into 3.x)","cause":"Trying to use with Prettier 3.x","error":"Error: prettier-plugin-md-nocjsp is only compatible with Prettier 2.x"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}