striveCode icon indicating copy to clipboard operation
striveCode copied to clipboard

braft-editor使用

Open itstrive opened this issue 7 years ago • 0 comments

编辑器回显注意事项

此处说的1版本,正常情况使用 initialContent , 文档也说了,默认只会在第一次传入的时候有效,也就是比如使用react异步获取的值,就可能出问题。 解决:

  • 配合 contentId 属性,一定注意, contentId 必须也变化,比如: 随机一个
  • 使用实力的方法 setContent

具体参考: https://github.com/margox/braft-editor/blob/old-master/README.md

itstrive avatar Oct 15 '18 02:10 itstrive