bustle / ember-mobiledoc-editor

MIT License
86 stars 48 forks source link

Disabling grammarly with ember-mobile-doc #159

Open nolman opened 5 years ago

nolman commented 5 years ago

Mobile doc and grammarly do not play well together. I don't believe it is currently possible to use the suggested workaround in ember-mobiledoc-editor? Setting data-gramm="false" does nothing.

Maybe I am missing something? If not I can open a PR to fix this.

chrisgame commented 5 years ago

I've fixed it by adding the following to the component I have that wraps ember-mobiledoc-editor

didRender() {                                                                                                                                                                                                                     
  let editorElement = this.element.querySelector('.mobiledoc-editor__editor');                                                                                                                                                    
  editorElement.setAttribute('data-gramm', false);                                                                                                                                                                                
},