Skip to content

Latest commit

 

History

History
36 lines (27 loc) · 783 Bytes

Readme.md

File metadata and controls

36 lines (27 loc) · 783 Bytes

embed-plugin-url

A plugin that can be used to parse urls into anchor tags.

Installation

npm i -S embed-js embed-plugin-url

CDN

https://unpkg.com/embed-plugin-url

Usage

Edit embed.js - url

Parsing urls into anchor tags.

import EmbedJS from 'embed-js'
import url from 'embed-plugin-url'

const x = new EmbedJS({
  input: document.getElementById('element'),
  plugins: [
    url({
        attributes: {}, // a hash of attributes to be added in the url
        escape: false   // whether on not to escape special characters in url
    })
  ]
})

Note : Avoid using escape: true when using with highlight plugin.

License

MIT @ Ritesh Kumar