Friday, July 28, 2017

reactjs : draftjs how to initiate an editor with content



Stumbled on this cool text editor, draft.js by facebook. I try to follow the example in github but I want to create an editor with content instead an empty editor. The first argument to EditorState.createWithContent is a ContentState, not a string. You need to import ContentState

No comments:

Moving Backgrounds With Mouse Position

Let's say you wanted to move the background-position on an element as you mouse over it to give the design a little pizzazz. You have ...