surmon-china / ngx-quill-editor

🍡@quilljs editor component for @angular
https://github.surmon.me/ngx-quill-editor
MIT License
232 stars 54 forks source link

"export 'DOCUMENT' was not found in '@angular/platform-browser' Fix for Angular 8 #71

Open JamieBohannaWebDev opened 4 years ago

JamieBohannaWebDev commented 4 years ago

The documentation for Angular 8 is outdated.

It states to run npm install ngx-quill-editor --save but this installs an old version of quill.

By running npm install ngx-quill@3.0.0 this fixed it.

After doing that however, I got the following error:

export 'DOCUMENT' was not found in '@angular/platform-browser'.

Withing /node_modules/ngx-quill/src/quill-editor.component.ts, on line 4 is:

import { DOCUMENT } from '@angular/platform-browser';

Please change this to import { DOCUMENT } from '@angular/common';

I believe this changed in Angular 4/5.