{"id":46232,"library":"remark-lint-fenced-code-marker","title":"remark-lint-fenced-code-marker","description":"remark-lint rule that warns when fenced code block markers (backticks or tildes) are inconsistent. Version 4.0.1, part of the remark-lint ecosystem. It checks that all fenced code blocks use the same marker style, defaulting to 'consistent' (first style detected). Works with unified processor, ships TypeScript types, ESM-only since version 4, actively maintained. Recommended preset uses backticks.","status":"active","version":"4.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/remarkjs/remark-lint#main","tags":["javascript","code","fenced","lint","marker","remark","remark-lint","remark-lint-rule","rule","typescript"],"install":[{"cmd":"npm install remark-lint-fenced-code-marker","lang":"bash","label":"npm"},{"cmd":"yarn add remark-lint-fenced-code-marker","lang":"bash","label":"yarn"},{"cmd":"pnpm add remark-lint-fenced-code-marker","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"required peer dependency for remark-lint integration","package":"unified","optional":false},{"reason":"required peer dependency to activate lint rules","package":"remark-lint","optional":false}],"imports":[{"note":"Package is ESM-only since v4; CommonJS require() will fail.","wrong":"const remarkLintFencedCodeMarker = require('remark-lint-fenced-code-marker')","symbol":"default","correct":"import remarkLintFencedCodeMarker from 'remark-lint-fenced-code-marker'"},{"note":"Marker is a TypeScript type, use 'import type' for type-only imports.","wrong":"import { Marker } from 'remark-lint-fenced-code-marker'","symbol":"Marker","correct":"import type { Marker } from 'remark-lint-fenced-code-marker'"},{"note":"Options is a TypeScript type; use 'import type' or ignore if not using TS.","wrong":"const { Options } = require('remark-lint-fenced-code-marker')","symbol":"Options","correct":"import type { Options } from 'remark-lint-fenced-code-marker'"}],"quickstart":{"code":"import { unified } from 'unified';\nimport remarkParse from 'remark-parse';\nimport remarkStringify from 'remark-stringify';\nimport remarkLint from 'remark-lint';\nimport remarkLintFencedCodeMarker from 'remark-lint-fenced-code-marker';\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(remarkLintFencedCodeMarker, '`')\n  .use(remarkStringify)\n  .process(file);\n\nconsole.error(reporter(file));","lang":"typescript","description":"Sets up a unified pipeline to lint fenced code marker style in an MD file, enforcing backticks."},"warnings":[{"fix":"Switch to dynamic import() or update project to ESM.","message":"Package is now ESM-only; CommonJS require() will throw ERR_REQUIRE_ESM.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"Upgrade Node.js to version 16 or higher.","message":"Unified ecosystem now requires Node.js >=16.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"Add .use(remarkLint) before rule plugins.","message":"'remark-lint' must be explicitly added before rule plugins; auto-registration removed.","severity":"deprecated","affected_versions":">=4.0.0"},{"fix":"Explicitly set option to '`' or '~' to enforce a specific style.","message":"Options default to 'consistent' which detects first marker; if file has mixed markers, only the first is used as standard.","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"search_vec":"'4':62 '4.0.1':24 'activ':63 'backtick':18,68 'block':16,38 'check':33 'code':5,15,37,70 'consist':46 'default':44 'detect':49 'ecosystem':31 'esm':58 'esm-on':57 'fenc':4,14,36,71 'first':47 'inconsist':22 'javascript':69 'lint':3,9,30,72,77,80 'maintain':64 'marker':6,17,42,73 'part':25 'preset':66 'processor':53 'recommend':65 'remark':2,8,29,74,76,79 'remark-lint':7,28,75 'remark-lint-fenced-code-mark':1 'remark-lint-rul':78 'rule':10,81,82 'ship':54 'sinc':60 'style':43,48 'tild':20 'type':56 'typescript':55,83 'unifi':52 'use':39,67 'version':23,61 'warn':12 'work':50","created_at":"2026-06-07T12:58:55.759535+00:00","updated_at":"2026-06-07T12:58:55.759535+00:00","problems":[{"fix":"Use import or upgrade to ESM: switch project to 'type': 'module' in package.json.","cause":"Using CommonJS require() on an ESM-only package (v4+).","error":"ERR_REQUIRE_ESM: require() of ES Module"},{"fix":"Run 'npm install remark-lint-fenced-code-marker' and ensure unified and remark-lint are installed.","cause":"Package not installed or version mismatch with peer dependencies.","error":"Error: Cannot find module 'remark-lint-fenced-code-marker'"},{"fix":"Use import syntax and ensure .use(remarkLint) is added before the rule plugin.","cause":"CommonJS require() returns an object with default property for ESM packages; also likely missing .use(remarkLint) before.","error":"TypeError: remarkLintFencedCodeMarker is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/remarkjs/remark-lint/tree/main#readme","github":"https://github.com/remarkjs/remark-lint#main","docs":null,"changelog":null,"pypi":null,"npm":"remark-lint-fenced-code-marker","openapi_spec":null,"status_page":null,"smithery":null,"categories":["testing"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}