I use bower to manage my js packages. I installed CKEditor into bower directory and it worked fine.
The question is: how should I add external plugins to ckeditor? I read here http://ckeditor.com/blog/CKEditor-Supports-Bower-and-Composer that this is possible by using extraPlugins property. But obviously I should somehow download plugin and add it to ckeditor/plugins folder. I'm quite new to bower but as I understand I shouldn't manually add any files or folders into bower directory. Instead I should use bower install plugin_name
or something like that.
So, if I simple write it like:
CKEDITOR.replace('pageContent', {
extraPlugins: 'Syntaxhighlighter Interface'
});
I got an error that the plugins is not found
As far as I can see you can't just use Bower to care about the CKEditor plugins but at least you can add plugins from an external folder with this command:
CKEDITOR.plugins.addExternal( 'sample', '/myplugins/sample/' );
/myplugins/sample/
is a path to the folder where the plugin.js
file is relative to the web root. sample
is the name of the plugin.
Check out the docs on this:
http://docs.ckeditor.com/#!/api/CKEDITOR.resourceManager-method-addExternal
With the page you linked mentions that Ckeditor iteself can be downloaded with bower
but not the plugins. After you download the plugins you need to enable them with the extraPlugins
option. To download the actual plugin I would use the plugin's download link like so:
bower install http://mydomain/somefile.zip
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With