{"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"bugs":{"url":"https://github.com/remarkjs/remark-lint/issues"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com"}],"dependencies":{"@types/mdast":"^4.0.0","unified-lint-rule":"^3.0.0","unist-util-position":"^5.0.0","unist-util-visit-parents":"^6.0.0","vfile-message":"^4.0.0"},"description":"remark-lint rule to warn when importance (strong) markers violate the given style","exports":"./index.js","funding":{"type":"opencollective","url":"https://opencollective.com/unified"},"keywords":["importance","lint","marker","remark","remark-lint","remark-lint-rule","rule","strong"],"license":"MIT","name":"remark-lint-strong-marker","repository":{"type":"git","url":"git+https://github.com/remarkjs/remark-lint.git#main"},"scripts":{},"sideEffects":false,"typeCoverage":{"atLeast":100,"strict":true},"type":"module","version":"4.0.1","xo":{"prettier":true,"rules":{"capitalized-comments":"off"}},"_id":"remark-lint-strong-marker@4.0.1","gitHead":"46ccbcd49deaada0172ad10425a2cd6b5f21a2c2","types":"./index.d.ts","homepage":"https://github.com/remarkjs/remark-lint/tree/main#readme","_nodeVersion":"23.1.0","_npmVersion":"11.0.0","dist":{"integrity":"sha512-KaGtj/OWEP4eoafevnlp3NsEVwC7yGEjBJ6uFMzfjNoXyjATdfZ2euB/AfKVt/A/FdZeeMeVoAUFH4DL+hScLQ==","shasum":"78f5001a492bae6cdc76fa71fbb8718dd6838d86","tarball":"http://registry-npm.ywwl.com/remark-lint-strong-marker/download/remark-lint-strong-marker-4.0.1.tgz","fileCount":5,"unpackedSize":15411,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIBBi4mhRcPD+KX1MWtvDEV4NbKp7w9cifg4M7DDI1x9mAiEAmVW2qhwfQ/4WNsMwQAE7aXupo2ScFK0VKruTn+uSOvQ="}],"size":4571,"noattachment":false,"key":"/remark-lint-strong-marker/-/remark-lint-strong-marker-4.0.1.tgz"},"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/remark-lint-strong-marker_4.0.1_1737981354919_0.8936218196962571"},"_hasShrinkwrap":false,"readme":"<!--This file is generated-->\n\n# remark-lint-strong-marker\n\n[![Build][badge-build-image]][badge-build-url]\n[![Coverage][badge-coverage-image]][badge-coverage-url]\n[![Downloads][badge-downloads-image]][badge-downloads-url]\n[![Size][badge-size-image]][badge-size-url]\n[![Sponsors][badge-funding-sponsors-image]][badge-funding-url]\n[![Backers][badge-funding-backers-image]][badge-funding-url]\n[![Chat][badge-chat-image]][badge-chat-url]\n\n[`remark-lint`][github-remark-lint] rule to warn when strong markers are inconsistent.\n\n## Contents\n\n* [What is this?](#what-is-this)\n* [When should I use this?](#when-should-i-use-this)\n* [Presets](#presets)\n* [Install](#install)\n* [Use](#use)\n* [API](#api)\n  * [`unified().use(remarkLintStrongMarker[, options])`](#unifieduseremarklintstrongmarker-options)\n  * [`Marker`](#marker)\n  * [`Options`](#options)\n* [Recommendation](#recommendation)\n* [Fix](#fix)\n* [Examples](#examples)\n* [Compatibility](#compatibility)\n* [Contribute](#contribute)\n* [License](#license)\n\n## What is this?\n\nThis package checks the style of strong markers.\n\n## When should I use this?\n\nYou can use this package to check that strong is consistent.\n\n## Presets\n\nThis plugin is included in the following presets:\n\n| Preset | Options |\n| - | - |\n| [`remark-preset-lint-consistent`](https://github.com/remarkjs/remark-lint/tree/main/packages/remark-preset-lint-consistent) | `'consistent'` |\n| [`remark-preset-lint-markdown-style-guide`](https://github.com/remarkjs/remark-lint/tree/main/packages/remark-preset-lint-markdown-style-guide) | `'*'` |\n\n## Install\n\nThis package is [ESM only][github-gist-esm].\nIn Node.js (version 16+),\ninstall with [npm][npm-install]:\n\n```sh\nnpm install remark-lint-strong-marker\n```\n\nIn Deno with [`esm.sh`][esm-sh]:\n\n```js\nimport remarkLintStrongMarker from 'https://esm.sh/remark-lint-strong-marker@4'\n```\n\nIn browsers with [`esm.sh`][esm-sh]:\n\n```html\n<script type=\"module\">\n  import remarkLintStrongMarker from 'https://esm.sh/remark-lint-strong-marker@4?bundle'\n</script>\n```\n\n## Use\n\nOn the API:\n\n```js\nimport remarkLint from 'remark-lint'\nimport remarkLintStrongMarker from 'remark-lint-strong-marker'\nimport remarkParse from 'remark-parse'\nimport remarkStringify from 'remark-stringify'\nimport {read} from 'to-vfile'\nimport {unified} from 'unified'\nimport {reporter} from 'vfile-reporter'\n\nconst file = await read('example.md')\n\nawait unified()\n  .use(remarkParse)\n  .use(remarkLint)\n  .use(remarkLintStrongMarker)\n  .use(remarkStringify)\n  .process(file)\n\nconsole.error(reporter(file))\n```\n\nOn the CLI:\n\n```sh\nremark --frail --use remark-lint --use remark-lint-strong-marker .\n```\n\nOn the CLI in a config file (here a `package.json`):\n\n```diff\n …\n \"remarkConfig\": {\n   \"plugins\": [\n     …\n     \"remark-lint\",\n+    \"remark-lint-strong-marker\",\n     …\n   ]\n }\n …\n```\n\n## API\n\nThis package exports no identifiers.\nIt exports the [TypeScript][typescript] types\n[`Marker`][api-marker] and\n[`Options`][api-options].\nThe default export is\n[`remarkLintStrongMarker`][api-remark-lint-strong-marker].\n\n### `unified().use(remarkLintStrongMarker[, options])`\n\nWarn when strong markers are inconsistent.\n\n###### Parameters\n\n* `options` ([`Options`][api-options], default: `'consistent'`)\n  — preferred style or whether to detect the first style and warn for\n  further differences\n\n###### Returns\n\nTransform ([`Transformer` from `unified`][github-unified-transformer]).\n\n### `Marker`\n\nMarker (TypeScript type).\n\n###### Type\n\n```ts\ntype Marker = '*' | '_'\n```\n\n### `Options`\n\nConfiguration (TypeScript type).\n\n###### Type\n\n```ts\ntype Options = Marker | 'consistent'\n```\n\n## Recommendation\n\nWhether asterisks or underscores are used affects how and whether strong\nworks.\nUnderscores are sometimes used to represent normal underscores inside words,\nso there are extra rules in markdown to support that.\nAsterisks are not used in natural language,\nso they don’t need these rules,\nand thus can form strong in more cases.\nAsterisks can also be used as the marker of more constructs than underscores:\nlists.\nDue to having simpler parsing rules,\nlooking more like syntax,\nand that they can be used for more constructs,\nit’s recommended to prefer asterisks.\n\n## Fix\n\n[`remark-stringify`][github-remark-stringify] formats strong with asterisks\nby default.\nPass `strong: '_'` to always use underscores.\n\n## Examples\n\n##### `ok-asterisk.md`\n\nWhen configured with `'*'`.\n\n###### In\n\n```markdown\n**Mercury**.\n```\n\n###### Out\n\nNo messages.\n\n##### `not-ok-asterisk.md`\n\nWhen configured with `'*'`.\n\n###### In\n\n```markdown\n__Mercury__.\n```\n\n###### Out\n\n```text\n1:1-1:12: Unexpected strong marker `_`, expected `*`\n```\n\n##### `ok-underscore.md`\n\nWhen configured with `'_'`.\n\n###### In\n\n```markdown\n__Mercury__.\n```\n\n###### Out\n\nNo messages.\n\n##### `not-ok-underscore.md`\n\nWhen configured with `'_'`.\n\n###### In\n\n```markdown\n**Mercury**.\n```\n\n###### Out\n\n```text\n1:1-1:12: Unexpected strong marker `*`, expected `_`\n```\n\n##### `not-ok-consistent.md`\n\n###### In\n\n```markdown\n**Mercury** and __Venus__.\n```\n\n###### Out\n\n```text\n1:17-1:26: Unexpected strong marker `_`, expected `*`\n```\n\n##### `not-ok.md`\n\nWhen configured with `'🌍'`.\n\n###### Out\n\n```text\n1:1: Unexpected value `🌍` for `options`, expected `'*'`, `'_'`, or `'consistent'`\n```\n\n## Compatibility\n\nProjects maintained by the unified collective are compatible with maintained\nversions of Node.js.\n\nWhen we cut a new major release, we drop support for unmaintained versions of\nNode.\nThis means we try to keep the current release line,\n`remark-lint-strong-marker@4`,\ncompatible with Node.js 16.\n\n## Contribute\n\nSee [`contributing.md`][github-dotfiles-contributing] in [`remarkjs/.github`][github-dotfiles-health] for ways\nto get started.\nSee [`support.md`][github-dotfiles-support] for ways to get help.\n\nThis project has a [code of conduct][github-dotfiles-coc].\nBy interacting with this repository, organization, or community you agree to\nabide by its terms.\n\n## License\n\n[MIT][file-license] © [Titus Wormer][author]\n\n[api-marker]: #marker\n\n[api-options]: #options\n\n[api-remark-lint-strong-marker]: #unifieduseremarklintstrongmarker-options\n\n[author]: https://wooorm.com\n\n[badge-build-image]: https://github.com/remarkjs/remark-lint/workflows/main/badge.svg\n\n[badge-build-url]: https://github.com/remarkjs/remark-lint/actions\n\n[badge-chat-image]: https://img.shields.io/badge/chat-discussions-success.svg\n\n[badge-chat-url]: https://github.com/remarkjs/remark/discussions\n\n[badge-coverage-image]: https://img.shields.io/codecov/c/github/remarkjs/remark-lint.svg\n\n[badge-coverage-url]: https://codecov.io/github/remarkjs/remark-lint\n\n[badge-downloads-image]: https://img.shields.io/npm/dm/remark-lint-strong-marker.svg\n\n[badge-downloads-url]: https://www.npmjs.com/package/remark-lint-strong-marker\n\n[badge-funding-backers-image]: https://opencollective.com/unified/backers/badge.svg\n\n[badge-funding-sponsors-image]: https://opencollective.com/unified/sponsors/badge.svg\n\n[badge-funding-url]: https://opencollective.com/unified\n\n[badge-size-image]: https://img.shields.io/bundlejs/size/remark-lint-strong-marker\n\n[badge-size-url]: https://bundlejs.com/?q=remark-lint-strong-marker\n\n[esm-sh]: https://esm.sh\n\n[file-license]: https://github.com/remarkjs/remark-lint/blob/main/license\n\n[github-dotfiles-coc]: https://github.com/remarkjs/.github/blob/main/code-of-conduct.md\n\n[github-dotfiles-contributing]: https://github.com/remarkjs/.github/blob/main/contributing.md\n\n[github-dotfiles-health]: https://github.com/remarkjs/.github\n\n[github-dotfiles-support]: https://github.com/remarkjs/.github/blob/main/support.md\n\n[github-gist-esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c\n\n[github-remark-lint]: https://github.com/remarkjs/remark-lint\n\n[github-remark-stringify]: https://github.com/remarkjs/remark/tree/main/packages/remark-stringify\n\n[github-unified-transformer]: https://github.com/unifiedjs/unified#transformer\n\n[npm-install]: https://docs.npmjs.com/cli/install\n\n[typescript]: https://www.typescriptlang.org\n","publish_time":1737981355101,"maintainers":[{"name":"johno","email":"johnotander@gmail.com"},{"name":"wooorm","email":"tituswormer@gmail.com"},{"name":"remcohaszing","email":"remcohaszing@gmail.com"}],"_cnpm_publish_time":1737981355101,"dist-tags":{"latest":"4.0.1"}}