{"id":26256,"library":"remark-lint-no-file-name-mixed-case","title":"remark-lint-no-file-name-mixed-case","description":"remark-lint rule to warn when file names use mixed case (e.g., 'MyFile.md' instead of 'myfile.md' or 'MYFILE.md'). Version 3.0.1 is the current stable release, published as part of the remark-lint monorepo. This package helps enforce consistent casing for Markdown file names in projects. It is ESM-only, requires Node.js 16+, and integrates with unified/remark. No configuration options.","status":"active","version":"3.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/remarkjs/remark-lint#main","tags":["javascript","case","file","lint","name","remark","remark-lint","remark-lint-rule","rule","typescript"],"install":[{"cmd":"npm install remark-lint-no-file-name-mixed-case","lang":"bash","label":"npm"},{"cmd":"yarn add remark-lint-no-file-name-mixed-case","lang":"bash","label":"yarn"},{"cmd":"pnpm add remark-lint-no-file-name-mixed-case","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency for remark-lint integration","package":"unified","optional":true},{"reason":"When using the CLI or API, remark-lint must be included as a separate plugin","package":"remark-lint","optional":true}],"imports":[{"note":"This package is ESM-only. CommonJS require() will fail. Use dynamic import() if needed.","wrong":"const remarkLintNoFileNameMixedCase = require('remark-lint-no-file-name-mixed-case')","symbol":"default","correct":"import remarkLintNoFileNameMixedCase from 'remark-lint-no-file-name-mixed-case'"},{"note":"This package has a default export only. Named import will not work.","wrong":"import { remarkLintNoFileNameMixedCase } from 'remark-lint-no-file-name-mixed-case'","symbol":"remarkLintNoFileNameMixedCase","correct":"import remarkLintNoFileNameMixedCase from 'remark-lint-no-file-name-mixed-case'"},{"note":"No types are exported from this package beyond the default export. Use the default import with unified's Plugin type.","wrong":null,"symbol":"type (TypeScript)","correct":"import type { Plugin } from 'unified'"}],"quickstart":{"code":"import { unified } from 'unified';\nimport remarkParse from 'remark-parse';\nimport remarkStringify from 'remark-stringify';\nimport remarkLint from 'remark-lint';\nimport remarkLintNoFileNameMixedCase from 'remark-lint-no-file-name-mixed-case';\nimport { read } from 'to-vfile';\nimport { reporter } from 'vfile-reporter';\n\nconst file = await read('example.md');\n\nawait unified()\n  .use(remarkParse)\n  .use(remarkLint)\n  .use(remarkLintNoFileNameMixedCase)\n  .use(remarkStringify)\n  .process(file);\n\nconsole.error(reporter(file));","lang":"typescript","description":"Shows how to use the plugin with unified API to lint file names for mixed case."},"warnings":[{"fix":"Use import or dynamic import().","message":"Package is ESM-only; CommonJS require() will throw ERR_REQUIRE_ESM.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Do not pass any options when using the plugin.","message":"Options parameter is not supported; the plugin takes no options.","severity":"deprecated","affected_versions":">=1.0.0"},{"fix":"Use lowercase or uppercase file names consistently.","message":"The plugin checks the file name, not the content. It will warn for files like 'Mercury.md' (mixed case).","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Ensure remark-lint is added to the unified pipeline.","message":"The plugin requires remark-lint to be used as a separate plugin. Omitting remark-lint will result in no linting.","severity":"gotcha","affected_versions":">=1.0.0"},{"fix":"Upgrade Node.js to version 16 or later.","message":"Node.js version must be >=16. Using older versions will cause failures.","severity":"gotcha","affected_versions":">=3.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Change to import statement or use dynamic import().","cause":"Using CommonJS require() to import an ESM-only package.","error":"Error [ERR_REQUIRE_ESM]: require() of ES Module /path/to/remark-lint-no-file-name-mixed-case/index.js from /path/to/file.js not supported."},{"fix":"Use default import: import remarkLintNoFileNameMixedCase from 'remark-lint-no-file-name-mixed-case'","cause":"Trying to import a named export when the package only has a default export.","error":"SyntaxError: The requested module 'remark-lint-no-file-name-mixed-case' does not provide an export named 'remarkLintNoFileNameMixedCase'"},{"fix":"Install remark-lint: npm install remark-lint","cause":"remark-lint is not installed. The plugin depends on remark-lint to function.","error":"Error: Cannot find package 'remark-lint' from '...'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}