Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Try to clarify loading editor styles #14917

Merged
merged 2 commits into from
Apr 11, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/designers-developers/developers/themes/theme-support.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,13 +223,13 @@ Note you don't need to add `add_theme_support( 'editor-styles' );` twice, but th

### Enqueuing the editor style

To make sure your editor style is loaded and parsed correctly, enqueue it using the following method:
Use the `add_editor_style` function to enqueue and load CSS on the editor screen. For the classic editor, this was the only function needed to add style to the editor. For the new block editor, you first need to `add_theme_support( 'editor-styles');` mentioned above.

```php
add_editor_style( 'style-editor.css' );
```

It is enough to paste that in your `functions.php` file, for the style to be loaded and parsed.
Adding that to your `functions.php` file will add the stylesheet `style-editor.css` to the queue of stylesheets to be loaded in the editor.

### Basic colors

Expand Down