Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/editor-js/raw
Raw HTML tool for Editor.js
https://github.com/editor-js/raw
editorjs
Last synced: 4 days ago
JSON representation
Raw HTML tool for Editor.js
- Host: GitHub
- URL: https://github.com/editor-js/raw
- Owner: editor-js
- License: mit
- Created: 2017-09-01T23:42:12.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2023-11-19T10:39:11.000Z (12 months ago)
- Last Synced: 2024-10-01T17:18:54.141Z (about 1 month ago)
- Topics: editorjs
- Language: JavaScript
- Homepage:
- Size: 449 KB
- Stars: 55
- Watchers: 7
- Forks: 27
- Open Issues: 15
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-ccamel - editor-js/raw - Raw HTML tool for Editor.js (JavaScript)
- awesome-editorjs - @editorjs/raw
README
![](https://badgen.net/badge/CodeX%20Editor/v2.0/blue)
# Raw HTML Tool for Editor.js
Raw Tool for the [Editor.js](https://codex.so/editor) allows to include raw HTML code in your articles.
![](https://capella.pics/5195d944-966d-40cf-8f86-78c6349d94cb.jpg)
## Installation
Get the package
```shell
yarn add @editorjs/raw
```Include module at your application
```javascript
import RawTool from '@editorjs/raw';
```Optionally, you can load this tool from CDN [JsDelivr CDN](https://cdn.jsdelivr.net/npm/@editorjs/raw@latest)
## Usage
Add a new Tool to the `tools` property of the CodeX Editor initial config.
```javascript
var editor = CodexEditor({
...
tools: {
...
raw: RawTool,
}
...
});
```## Config Params
| Field | Type | Description |
| ----------- | -------- | ------------------------------|
| placeholder | `string` | Raw Tool's placeholder string |## Output data
This Tool returns raw HTML code.
```json
{
"type" : "raw",
"data" : {
"html": "Any HTML code",
}
}
```