Skip to content

Commit

Permalink
Merge stable into master
Browse files Browse the repository at this point in the history
  • Loading branch information
CKEditorBot authored Dec 16, 2024
2 parents 3b739bf + cbca86f commit 1b350d4
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docs/tutorials/crash-course/editor.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ import 'ckeditor5/ckeditor5.css';
const element = document.querySelector( '#app' );

// Instantiate the editor using the `create` method.
const editor = await ClassicEditor.create( element );
const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL' // Or '<YOUR_LICENSE_KEY>'.
} );
```

As you can see, the {@link module:core/editor/editor~Editor.create `create()`} method creates a new editor instance. It replaces the DOM element passed as the first argument with the editor UI, and sets the initial state of the editor to the content of that DOM element.
Expand All @@ -63,6 +65,7 @@ import { Essentials, Paragraph } from 'ckeditor5';

// Update the call to the `create()` method.
const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL', // Or '<YOUR_LICENSE_KEY>'.
plugins: [
Essentials,
Paragraph
Expand Down
2 changes: 2 additions & 0 deletions docs/tutorials/crash-course/plugin-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ In this tutorial, we will add a single option to the `highlight` plugin to confi

```js
const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL', // Or '<YOUR_LICENSE_KEY>'.
// Other options are omitted for readability - do not remove them.
highlight: {

Expand Down Expand Up @@ -71,6 +72,7 @@ Then, open the `src/main.js` file and update the editor's configuration to chang

```js
const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL', // Or '<YOUR_LICENSE_KEY>'.
// Other options are omitted for readability - do not remove them.
highlight: {
keystroke: 'Ctrl+Alt+9'
Expand Down
2 changes: 2 additions & 0 deletions docs/tutorials/crash-course/plugins.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ In the previous chapter of this tutorial, we learned that the editor is just an
import { Essentials, Paragraph } from 'ckeditor5';

const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL', // Or '<YOUR_LICENSE_KEY>'.
plugins: [
Essentials,
Paragraph
Expand Down Expand Up @@ -69,6 +70,7 @@ Then, in the `src/main.js` file, import and register this function as an editor
import { Highlight } from './plugin';

const editor = await ClassicEditor.create( element, {
licenseKey: 'GPL', // Or '<YOUR_LICENSE_KEY>'.
plugins: [
// Other plugins are omitted for readability - do not remove them.
Highlight
Expand Down

0 comments on commit 1b350d4

Please sign in to comment.