diff --git a/README.md b/README.md index 633dedeb..72357b9f 100644 --- a/README.md +++ b/README.md @@ -157,24 +157,26 @@ export default { data () { // editor extensions // they will be added to menubar and bubble menu by the order you declare. - extensions: [ - new Doc(), - new Text(), - new Paragraph(), - new Heading({ level: 5 }), - new Bold({ bubble: true }), // render command-button in bubble menu. - new Underline({ bubble: true, menubar: false }), // render command-button in bubble menu but not in menubar. - new Italic(), - new Strike(), - new ListItem(), - new BulletList(), - new OrderedList(), - ], - // editor's content - content: ` -

Heading

-

This Editor is awesome!

- `, + return { + extensions: [ + new Doc(), + new Text(), + new Paragraph(), + new Heading({ level: 5 }), + new Bold({ bubble: true }), // render command-button in bubble menu. + new Underline({ bubble: true, menubar: false }), // render command-button in bubble menu but not in menubar. + new Italic(), + new Strike(), + new ListItem(), + new BulletList(), + new OrderedList(), + ], + // editor's content + content: ` +

Heading

+

This Editor is awesome!

+ `, + }; }, }, diff --git a/README_ZH.md b/README_ZH.md index 51697034..28aa065e 100644 --- a/README_ZH.md +++ b/README_ZH.md @@ -157,24 +157,26 @@ export default { data () { // 编辑器的 extensions // 它们将会按照你声明的顺序被添加到菜单栏和气泡菜单中 - extensions: [ - new Doc(), - new Text(), - new Paragraph(), - new Heading({ level: 5 }), - new Bold({ bubble: true }), // 在气泡菜单中渲染菜单按钮 - new Underline({ bubble: true, menubar: false }), // 在气泡菜单而不在菜单栏中渲染菜单按钮 - new Italic(), - new Strike(), - new ListItem(), - new BulletList(), - new OrderedList(), - ], - // 编辑器的内容 - content: ` -

Heading

-

This Editor is awesome!

- `, + return { + extensions: [ + new Doc(), + new Text(), + new Paragraph(), + new Heading({ level: 5 }), + new Bold({ bubble: true }), // 在气泡菜单中渲染菜单按钮 + new Underline({ bubble: true, menubar: false }), // 在气泡菜单而不在菜单栏中渲染菜单按钮 + new Italic(), + new Strike(), + new ListItem(), + new BulletList(), + new OrderedList(), + ], + // 编辑器的内容 + content: ` +

Heading

+

This Editor is awesome!

+ `, + }; }, },