Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ngFor with ng2-ckeditor

See original GitHub issue

I use ckditor with ngFor, please see plnkr below. plnkr:

  • when click button remove me 0, and then ckeditor break.
  • when click button remove me 1, ckeditor still can use.

Did I miss something?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

chymzcommented, Aug 2, 2016

Here is the fix :

You need to include divarea plugin :

<ckeditor [(ngModel)]="content" [config]="{extraPlugins: 'divarea'}"></ckeditor>

Inline mode is not available atm.

Thanks for reporting this !

rmcsharrycommented, Oct 13, 2017

Note that using ‘divarea’ does make this error go away BUT the side effect is that now you are using a div for the editor instead of the standard hidden textarea you get with the iFrame of ckeditor out of the box. This means that the CSS styles for your website now apply inside the div (ie. inside the editor area itself). So the user changing things like font style and size could easily get unexpected results.

The correct solution to this problem is to implement the ngOnDestroy hook in your component and destroy the instance of the editor, as shown here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ng2-ckeditor set value by typescript - Stack Overflow
In component, I have the following: let group = { 'porcentaje': [setup.porcentaje || '', Validators.compose([Validators.
Read more >
ng2-ckeditor/ - UNPKG
1, # Angular2 - CKEditor component. 2. 3, Use the [CKEditor (4.x)]( wysiwyg in your Angular2 application.
Read more >
Ng2 Ckeditor (forked) - StackBlitz
Starter project for ng2-ckeditor.
Read more >
ng2-ckeditor - npm Package Health Analysis - Snyk
ng2 -ckeditor · Angular CKEditor component For more information about how to use this package see README · Security · Popularity · Maintenance...
Read more >
How to Work with a Text Editor in an Angular 8 Application
Now install ng2-ckeditor library in this project, to install ng2-ckeditor library use the following command: npm install ng2-ckeditor. Now add ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found