{"library":"remark-lint-fenced-code-flag","title":"remark-lint-fenced-code-flag","description":"A remark-lint rule that warns when fenced code blocks lack a language flag (infostring) or use an unrecognized one. Current stable version 4.2.0, released as part of the remark-lint monorepo with regular updates tied to remark ecosystem releases. Differentiates from generic linting by optionally validating against GitHub Linguist flags, ensuring code highlighting compatibility. Ships TypeScript definitions, ESM-only, requires Node.js 16+. Part of the remark-lint preset family.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install remark-lint-fenced-code-flag"],"cli":null},"imports":["import remarkLintFencedCodeFlag from 'remark-lint-fenced-code-flag'","import { checkGithubLinguistFlag } from 'remark-lint-fenced-code-flag'","import type { CheckFlag } from 'remark-lint-fenced-code-flag'","import type { Options } from 'remark-lint-fenced-code-flag'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import { unified } from 'unified';\nimport remarkParse from 'remark-parse';\nimport remarkStringify from 'remark-stringify';\nimport remarkLint from 'remark-lint';\nimport remarkLintFencedCodeFlag from 'remark-lint-fenced-code-flag';\nimport { read } from 'to-vfile';\nimport { reporter } from 'vfile-reporter';\n\nconst file = await read('example.md');\nawait unified()\n  .use(remarkParse)\n  .use(remarkLint)\n  .use(remarkLintFencedCodeFlag, { allowEmpty: false })\n  .use(remarkStringify)\n  .process(file);\n\nconsole.error(reporter(file));","lang":"typescript","description":"Demonstrates how to set up a unified pipeline with remark-lint and the fenced-code-flag rule, reading a markdown file, processing with options, and reporting lint warnings.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}