New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

remark-select

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

remark-select

A remark plugin to parse select box syntax.

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

remark-select

A remark plugin that parse Mardown syntax to add support for select element.

Syntax

You can add a select element this way :

Who is the stronger ? : [ Samus | Peach | Zelda |v]

Wich leads to :

Screenshot

Installation

Easy as npm i

$ npm install remark-line-input

You install also that plugins : "unified remark-parse rehype-stringify remark-rehype"

$ npm install unified remark-parse rehype-stringify remark-rehype

Usage

An example of code :

const unified = require('unified')
const remarkParse = require('remark-parse')
const stringify = require('rehype-stringify')
const remark2rehype = require('remark-rehype')

const select = require('remark-select')

const testFile = `Choose a player : [ Luigi | Mario | Peach | Falco | Zelda |v]{.mario .link .starFox}

Choose an action : [ Start | Restart | Quit |v]`

unified()
  .use(remarkParse)
  .use(select)
  .use(remark2rehype) 
  .use(stringify)
  .process( testFile, (err, file) => {
    console.log(String(file));
  } );

Configuration

This plugin support custom HTML attributes :

[ Mario | Peach | Luigi |v]{.nintendo #select-character}

Licence

MIT

Keywords

select

FAQs

Package last updated on 21 Jan 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts