Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Install CKeditor using Bower

I am struggling to install ckeditor with Bower, I have tried a bunch of different things but each time I end up with just a .bower.json file and a Readme file or index file. I never get more than 2 files :( I am able to install other packages just fine, so I know things are set up ok.

Here are some things I have tried:

    {
       "dependencies": {
          "ckeditor": "latest",

          "ckeditor": "https://github.com/ckeditor/ckeditor-releases/releases/tag/4.2.1/standard",

          "ckeditor": "https://github.com/ckeditor/ckeditor-releases/releases/tag/4.2.1/standard",

          "ckeditor": "https://github.com/ckeditor/ckeditor-releases/commit/a822d585d4ebf8d969fa" 
       }
    }

Why is this package different than the rest? What is the key to crack it?

like image 281
Mike Avatar asked Dec 05 '22 09:12

Mike


2 Answers

Since version 4.3.3 CKEditor introduced support for Bower. You may simply install it with following command:

bower install ckeditor

You may also download it by setting dependencies in your bower.json:

{
    "name": "my-project",
    "dependencies": {
        "ckeditor": "4"
    }
}

After that fetch dependencies with:

bower update

Note: that it will download standard-all preset, which essentially contains all the official plugins available, but only part of them enabled in configuration.

More information can be found in CKEditor package managers guide.

like image 53
Marek Lewandowski Avatar answered Jan 25 '23 23:01

Marek Lewandowski


Sometimes you want a specific preset with a specific version of ckeditor.

First off, here is a helpful ckeditor post that will facilitate the required syntax to specify the repository tag.

Here is an example of what to include in your bower.json file:

{
 name: "your-name",
  "dependencies": {
      "ckeditor": "#full/4.3.3"
  }
}

Simply swap out 'full' with either basic, standard, or which ever you desire as well as the version.

then run:

bower update
like image 39
mkralla11 Avatar answered Jan 26 '23 00:01

mkralla11