tiptap/examples/Components/Routes/Title/Title.js
2019-06-21 22:00:42 +02:00

20 lines
260 B
JavaScript

import { Node } from 'tiptap'
export default class Title extends Node {
get name() {
return 'title'
}
get schema() {
return {
content: 'inline*',
parseDOM: [{
tag: 'h1',
}],
toDOM: () => ['h1', 0],
}
}
}