Hi,
I have a created a formula node in my schema.
formula : {
inline:true,
group: "inline",
selectable:true,
attrs:{
expression:""
},
toDOM(node){
return ["formula",{expression: node.attrs.expression}, node.attrs.expression]
},
parseDOM:[{
tag:"formula",
getAttrs(dom){
return {
expression: dom.attributes.expression.value
}
}
}]
}
My formula tag : <formula expression=“a+b”>a+b</formula>
So when i parse this tag is is possible to replace the “a+b” with other value?
I saw getContent option in parserule but im sure how it will work?