I’m trying to set up a simple prosemirror + vuejs example but I can’t make it work. Please look at this fiddle: https://codesandbox.io/s/prosemirror-vue-t8jbd
The BOLD button triggers the toggleMark function but it has no effect neither on the displayed text nor on the prosemirror state.
What am I doing wrong ?
I’ve made some adjustments in https://codesandbox.io/s/prosemirror-vue-ngomz that make it work. Basically, you don’t have to mess with
dispatchTransaction at all—in the simple case, the default will do what you need. Also, if you’re going to save a
this.state, you should make sure you update it when it changes (it’s not mutable, applying a transaction gives you a new state). I’ve adjusted it to just use
OK great ! many thanks for your help.
Le mer. 4 sept. 2019 à 12:54, Marijn Haverbeke via discuss.ProseMirror firstname.lastname@example.org a écrit :
Oh, one more thing @marijn : do you know why the Enter key press does not insert a new line / create new paragraph ?
Enter does nothing unless you bind it (see