@selective/marker

Rehype plugin to run selective lint

Usage no npm install needed!

<script type="module">
  import selectiveMarker from 'https://cdn.skypack.dev/@selective/marker';
</script>

README

Selective Marker">

NPM Version Linux Build Status Windows Build status

Parse selective rule comments from HTML, compatible unified-message-control.

Installation

# npm
npm install @selective/marker

# yarn
yarn add @selective/marker

Usage

const marker = require("@selective/marker");

const hastNode = {
  type: "comment",
  value: "selective ignore test",
};

const result = marker(hastNode);

console.log(result);
// {
//   name: "selective",
//   attributes: "ignore test",
//   parameters: {
//     ignore: true,
//     test: true
//   },
//   {
//     type: "comment",
//     value: "selective ignore test"
//   }
// }

References