{"library":"remark-lint-final-newline","title":"remark-lint-final-newline","description":"remark-lint rule to warn when a final newline character (\\n) is missing at the end of a file. Part of the remark-lint ecosystem, this plugin enforces POSIX-style file endings. Current stable version is 3.0.1 (ESM-only, requires Node.js 16+). It is included in the `remark-preset-lint-recommended` preset. Unlike some linters that auto-fix, this rule only warns; auto-fixing can be done via `remark-stringify`. No configuration options.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install remark-lint-final-newline"],"cli":{"name":"remark","version":null}},"imports":["import remarkLintFinalNewline from 'remark-lint-final-newline'","import remarkLintFinalNewline from 'remark-lint-final-newline'",".use(remarkLintFinalNewline)"],"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 remarkLintFinalNewline from 'remark-lint-final-newline';\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(remarkLintFinalNewline)\n  .use(remarkStringify)\n  .process(file);\n\nconsole.error(reporter(file));","lang":"typescript","description":"Set up unified pipeline with remark-parse, remark-lint, the rule, and remark-stringify to lint and optionally fix missing final newline.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}