workaround for tommoor/slate-md-serializer#14
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
fd4f9679df
commit
c3aef6e3a0
1 changed files with 5 additions and 0 deletions
|
@ -182,6 +182,11 @@ export default class MessageComposerInput extends React.Component {
|
|||
return `<u>${ children }</u>`;
|
||||
case 'deleted':
|
||||
return `<del>${ children }</del>`;
|
||||
case 'code':
|
||||
// XXX: we only ever get given `code` regardless of whether it was inline or block
|
||||
// XXX: workaround for https://github.com/tommoor/slate-md-serializer/issues/14
|
||||
// strip single backslashes from children, as they would have been escaped here
|
||||
return `\`${ children.split('\\').map((v) => v ? v : '\\').join('') }\``;
|
||||
}
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue