1.0.3 • Published 3 years ago

editorjs-youtube-embed v1.0.3

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

npm.io

Youtube Embed Tool

An Editor.js plugin to embed YouTube Video.

Simply copy and paste YouTube video URL to embed.

npm.io

Installation

Install via NPM

Get the package

npm i editorjs-youtube-embed

Include module at your application

const YoutubeEmbed = require('editorjs-youtube-embed');

Download to your project's source dir

  1. Download folder dist from repository
  2. Add dist/main.js file to your page.

Usage

Add a new Tool to the tools property of the Editor.js initial config.

var editor = EditorJS({
  ...
  
  tools: {
    ...
    youtubeEmbed: YoutubeEmbed,
  }
  
  ...
});

Config Params

This tool has no config params

Output data

FieldTypeDescription
urlstringvideo url
{
    "type": "youtubeEmbed",
    "data": {
        "url": "https://www.youtube.com/watch?v=L229QDxDakU"
    }
}
1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago