Grapesjs Plugin Header
npm install grapesjs-plugin-headerhtml
`
$3
`js
const editor = grapesjs.init({
container: '#gjs',
height: '100%',
fromElement: true,
storageManager: false,
plugins: ['grapesjs-plugin-header'],
});
`
$3
`css
body, html {
margin: 0;
height: 100%;
}
`
Summary
* Plugin name: grapesjs-plugin-header
* Components
* component-id-1
* component-id-2
* ...
* Blocks
* block-id-1
* block-id-2
* ...
Options
| Option | Description | Default |
|-|-|-
| option1 | Description option | default value |
Download
* CDN
* https://unpkg.com/grapesjs-plugin-header
* NPM
* npm i grapesjs-plugin-header
* GIT
* git clone https://github.com/olivmonnier/grapesjs-plugin-header.git
Usage
Directly in the browser
`html
`
Modern javascript
`js
import grapesjs from 'grapesjs';
import plugin from 'grapesjs-plugin-header';
import 'grapesjs/dist/css/grapes.min.css';
const editor = grapesjs.init({
container : '#gjs',
// ...
plugins: [plugin],
pluginsOpts: {
[plugin]: { / options / }
}
// or
plugins: [
editor => plugin(editor, { / options / }),
],
});
`
Development
Clone the repository
`sh
$ git clone https://github.com/olivmonnier/grapesjs-plugin-header.git
$ cd grapesjs-plugin-header
`
Install dependencies
`sh
$ npm i
`
Start the dev server
`sh
$ npm start
`
Build the source
`sh
$ npm run build
``