@advanced-rest-client/highlight

A set of tools to work with markdown content and other syntax highlighting.


Keywords
web-components, marked
License
Apache-2.0
Install
npm install @advanced-rest-client/highlight@2.0.2

Documentation

highlight

A set of tools to work with markdown content and other syntax highlighting.

This library replaces the old modules of:

  • @advanced-rest-client/markdown-styles
  • @advanced-rest-client/arc-marked
  • @advanced-rest-client/prism-highlight

Published on NPM

Tests and publishing

Usage

Installation

npm install --save @advanced-rest-client/highlight

MarkdownStyles

This should be used whenever the arc-marked is used.

import { MarkdownStyles } from '@advanced-rest-client/highlight';

export default class AnElement extends LitElement {
  get styles() {
    return [
      MarkdownStyles,
      css`
        ...
      `
    ];
  }
  ...
}

arc-marked

An element that specializes in markdown rendering.

<arc-marked markdown="***Bold and italic***">
  <div slot="markdown-html" class="markdown-html custom"></div>
</arc-marked>
<arc-marked>
  <div slot="markdown-html"></div>
  <script type="text/markdown">
    ## Markdown Renderer

    ...
  </script>
</arc-marked>

Development

git clone https://github.com/advanced-rest-client/arc-headers
cd arc-headers
npm install

Running the demo locally

npm start

Running the tests

npm test