Support for extraPlugins | strinsert
See original GitHub issueWe are trying to implement a custom dropdown in the toolbar using the following addon. https://ckeditor.com/cke4/addon/strinsert
We can get it to work by adding
declare var CKEDITOR: any
then configuring it with
CKEDITOR.plugins.addExternal( 'strinsert', '/assets/ckeditor_plugin/', 'plugin.js' )
and then finally we can actually use it in the variable we bind to [config]
this.ckeConfig = { allowedContent: true, extraPlugins: 'strinsert', strinsert_strings: shortcodeList ] }
This has a problem though as we are combining approaches and feels like it will break as I would think this is not how this library was intended to be used.
What’s the way that ng2-ckeditor is designed to include plugins for ckeditor? Is the way above correct? If it is, testing becomes difficult as declare var CKEDITOR: any
doesn’t exist when creating the component through karma and so tests related to the component the editor is included on will fail with
Failed: CKEDITOR is not defined ReferenceError: CKEDITOR is not defined
Issue Analytics
- State:
- Created 5 years ago
- Comments:8
Unfortunately, I can not help. No idea how to get karma work with global variable declaration. I leave the question open and hope someone else can help.
if the icon is a part of the plugin you can not