-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.js
56 lines (52 loc) · 1.44 KB
/
main.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import {addExtraBlocks} from './addBlocks.js';
import grapesjs from 'grapesjs';
import 'grapesjs/dist/css/grapes.min.css';
import gjsCode from 'grapesjs-script-editor'
import ckEditor from 'grapesjs-plugin-ckeditor'
import gjsBlocksBasic from 'grapesjs-blocks-basic';
import grapesjsPluginForms from 'grapesjs-plugin-forms';
import grapesjsComponentCountdown from 'grapesjs-component-countdown';
import grapesjsPluginExport from 'grapesjs-plugin-export';
import grapesjsTabs from 'grapesjs-tabs';
import grapesjsCustomCode from 'grapesjs-custom-code';
import grapesjsTouch from 'grapesjs-touch';
import grapesjsParserPostcss from 'grapesjs-parser-postcss';
import grapesjsTooltip from 'grapesjs-tooltip';
import grapesjsTuiImageEditor from 'grapesjs-tui-image-editor';
import grapesjsTyped from 'grapesjs-typed';
import grapesjsStyleBg from 'grapesjs-style-bg';
const editor = grapesjs.init({
container: '#gjs',
height: '98vh',
width: 'auto',
fromElement: true,
storageManager: false,
plugins: [
gjsCode,
gjsBlocksBasic,
grapesjsComponentCountdown,
grapesjsPluginForms,
grapesjsPluginExport,
grapesjsTabs,
grapesjsCustomCode,
grapesjsTouch,
grapesjsParserPostcss,
grapesjsTooltip,
grapesjsTuiImageEditor,
grapesjsTyped,
grapesjsStyleBg,
ckEditor,
],
jsInHtml: true,
allowScripts: 1,
pluginsOpts: {
[grapesjsTuiImageEditor]: {
config: {
includeUI: {
initMenu: 'filter',
}
}
},
},
});
addExtraBlocks(editor)