table
table copied to clipboard
Output contains classes
When i create this
This is the output
Would be nice to get clean data, not divs with classes etc in the output. Like on the Editor.js site
How do i achieve this ?
Found a workaround for this, overriding the table with:
class TableTool extends Table {
save(toolsContent) {
const table = toolsContent.querySelector('table');
const data = [];
const rows = table.rows;
for (let i = 0; i < rows.length; i++) {
const row = rows[i];
const cols = Array.from(row.cells);
const inputs = cols.map(cell => cell.querySelector('.tc-table__inp'));
const isWorthless = inputs.every(this._isEmpty);
if (isWorthless) {
continue;
}
data.push(inputs.map(input => {
return input.innerHTML
}));
}
return {
content: data
};
}
}
More to this, the two divs are wrapping the existing content each time you save. Kindly release the build with the fix at the earliest.