We have used this editor in Filament. I would however like to add a class to tables created with the editor. I cannot find how to do that in the plugin. I have seen some solutions for the tiptap editor in general but i cannot find how to do it in the plugin.
#awcodes-tiptap-editor
Solution
resource\js\tiptap\extensions.js
resource\js\tiptap\extensions.js
import Table from "@tiptap/extension-table";import TableCell from "@tiptap/extension-table-cell";import TableHeader from "@tiptap/extension-table-header";import TableRow from "@tiptap/extension-table-row";window.TiptapEditorExtensions = { table: [Table.configure({ HTMLAttributes: { class: 'tiptap-table' }, }), TableHeader, TableCell, TableRow],}
import Table from "@tiptap/extension-table";import TableCell from "@tiptap/extension-table-cell";import TableHeader from "@tiptap/extension-table-header";import TableRow from "@tiptap/extension-table-row";window.TiptapEditorExtensions = { table: [Table.configure({ HTMLAttributes: { class: 'tiptap-table' }, }), TableHeader, TableCell, TableRow],}