PHPackages                             marshmallow/nova-tinymce - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Templating &amp; Views](/categories/templating)
4. /
5. marshmallow/nova-tinymce

ActiveLibrary[Templating &amp; Views](/categories/templating)

marshmallow/nova-tinymce
========================

This Nova package allow you to use TinyMCE editor for text areas.You can customize the editor options and... you can upload images to your server and put them rigth there on the text without leaving the text editor!

v2.3.1(4mo ago)422.4k↑83.3%1[2 PRs](https://github.com/marshmallow-packages/nova-tinymce/pulls)2MITCSSPHP ^8.0CI failing

Since May 19Pushed 2d ago1 watchersCompare

[ Source](https://github.com/marshmallow-packages/nova-tinymce)[ Packagist](https://packagist.org/packages/marshmallow/nova-tinymce)[ RSS](/packages/marshmallow-nova-tinymce/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (9)Dependencies (1)Versions (34)Used By (2)

[![alt text](https://camo.githubusercontent.com/f5450f299f5713ce2f04dd5a1ba7ce9960ed4568b3574e4c4ee3cddc75477253/68747470733a2f2f6d617273686d616c6c6f772e6465762f63646e2f6d656469612f6c6f676f2d7265642d3233377834362e706e67 "marshmallow.")](https://camo.githubusercontent.com/f5450f299f5713ce2f04dd5a1ba7ce9960ed4568b3574e4c4ee3cddc75477253/68747470733a2f2f6d617273686d616c6c6f772e6465762f63646e2f6d656469612f6c6f676f2d7265642d3233377834362e706e67)

Laravel Nova TinyMCE editor
===========================

[](#laravel-nova-tinymce-editor)

[![Latest Version on Packagist](https://camo.githubusercontent.com/c9169b0341e74bc9744a606613ba38f7aba5bdeb2dc2a850dd69b7fcbb253c82/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d617273686d616c6c6f772f6e6f76612d74696e796d63652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/marshmallow/nova-tinymce)[![Total Downloads](https://camo.githubusercontent.com/1b1ac909490ac090793eb9f6582460daf356d19ce21b255dacda5478515e5516/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d617273686d616c6c6f772f6e6f76612d74696e796d63652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/marshmallow/nova-tinymce)

This Nova package allows you to use the [TinyMCE editor](https://tiny.cloud) for text areas. You can fully customize the editor options, define reusable styling, add custom buttons and variables, and optionally upload images straight into the editor.

[![Screenshot](docs/img.png)](docs/img.png)

Requirements
------------

[](#requirements)

- PHP `^8.0`
- Laravel Nova `^4.0` or `^5.0`

Installation
------------

[](#installation)

Install the package via Composer:

```
composer require marshmallow/nova-tinymce
```

Publish the TinyMCE JavaScript, CSS, and skin assets to your `public` directory:

```
php artisan vendor:publish --provider="Marshmallow\Nova\TinyMCE\FieldServiceProvider" --tag="resources"
```

This publishes the assets to `public/vendor/tinymce`. Republish them after every package update so the editor assets stay in sync.

### Publish the config file (optional)

[](#publish-the-config-file-optional)

Publish the config to override any of the default TinyMCE settings:

```
php artisan vendor:publish --provider="Marshmallow\Nova\TinyMCE\FieldServiceProvider" --tag="config"
```

Usage
-----

[](#usage)

Add the `TinyMCE` field to the `fields` array of your Nova resource. The field is hidden on the index view by default.

```
use Marshmallow\Nova\TinyMCE\TinyMCE;

public function fields(Request $request)
{
    return [
        ID::make()->sortable(),
        TinyMCE::make(__('Content'), 'content'),
    ];
}
```

### Set the height

[](#set-the-height)

The default height is defined in the `nova-tinymce.php` config file. Override it per field with the `height()` method:

```
TinyMCE::make('body')->height(300),
```

### Add custom HTML (buttons)

[](#add-custom-html-buttons)

Insert buttons or custom HTML with a single click using the `buttons()` method. The array key is the button label, the value is the HTML that gets inserted:

```
TinyMCE::make('body')->buttons([
    'Name button' => 'value of HTML',
    'Name button2' => 'More HTML',
]),
```

### Add variables

[](#add-variables)

Insert variables with a single click using the `variables()` method:

```
TinyMCE::make('body')->variables([
    'name_var' => 'value_var',
]),
```

### Set the toolbar

[](#set-the-toolbar)

Override the toolbar string for a single field with the `toolbar()` method:

```
TinyMCE::make('body')->toolbar('undo redo | bold italic | link'),
```

### Set the plugins

[](#set-the-plugins)

Override the active TinyMCE plugins for a single field with the `plugins()` method:

```
TinyMCE::make('body')->plugins(['lists', 'link', 'image', 'table']),
```

### Pass any TinyMCE option

[](#pass-any-tinymce-option)

Pass any option supported by the TinyMCE JavaScript SDK through the `options()` method. The given options are merged on top of the defaults:

```
TinyMCE::make('body')->options([
    'height' => '980',
]),
```

See the full list of options in the [TinyMCE configuration docs](https://www.tiny.cloud/docs/configure/).

### Add styling options per field

[](#add-styling-options-per-field)

Add one or more entries to the field's style format ("Content type") selector at runtime with `addStyle()` and `addStyles()`:

```
TinyMCE::make('body')->addStyle([
    'title' => 'Lead Paragraph',
    'block' => 'p',
    'classes' => 'lead',
]),

TinyMCE::make('body')->addStyles([
    ['title' => 'Lead Paragraph', 'block' => 'p', 'classes' => 'lead'],
    ['title' => 'Muted', 'inline' => 'span', 'classes' => 'text-muted'],
]),
```

### Add custom styling for all fields

[](#add-custom-styling-for-all-fields)

To add styling options available on every TinyMCE field, publish the config and add entries to the `custom_items` array. These appear in the editor's "Content type" selector:

```
'custom_items' => [
    // This adds a .lead class on the paragraph tag.
    [
        'title' => 'Lead Paragraph',
        'block' => 'p',
        'classes' => 'lead',
    ],
],
```

### File manager support

[](#file-manager-support)

The package ships a `use_lfm` config option to integrate with a Laravel file manager (set `use_lfm` to `true` and configure `lfm_url`). After installing your file manager, run the bundled command to drop in the package's file manager view override:

```
php artisan nova-tinymce:support-lfm
```

Configuration
-------------

[](#configuration)

The published `config/nova-tinymce.php` file exposes the defaults that are applied to every field. The most common keys:

KeyDefaultDescription`custom_items`one `Lead Paragraph` entryStyling items shown in the "Content type" selector for every field.`license_key``'gpl'`TinyMCE license key. Use `'gpl'` for the self-hosted GPL build.`cloud_api_key``null`TinyMCE Cloud API key, or `null` for self-hosted.`height``350`Default editor height in pixels.`content_css`oxide + `custom.css`Stylesheet(s) loaded inside the editor content area.`skin_url`oxide skin pathPath to the editor UI skin.`content_css_dark`oxide-dark content cssContent stylesheet used in dark mode.`skin_url_dark`oxide-dark skin pathUI skin used in dark mode.`plugins`array of TinyMCE pluginsPlugins enabled on every field.`menubar``'file edit view insert format tools table'`The editor menu bar.`toolbar`toolbar stringThe editor toolbar layout.`relative_urls``false`Whether URLs are converted to relative paths.`use_lfm``false`Enable Laravel file manager integration.`lfm_url``'filemanager'`URL of the file manager.`use_dark``true`Enable dark-mode skins.`browser_spellcheck``false`Use the browser's native spell checker.`link_class_list`preset button classesClass options offered when inserting a link.`table_class_list``Default`Class options for tables.`image_class_list``Default`Class options for images.`color_map`preset paletteThe editor color picker palette.`formats``[]`Custom TinyMCE `formats` definitions.`extra_options``[]`Any additional raw TinyMCE options merged into every field.See `config/nova-tinymce.php` for the complete list of available keys.

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [All Contributors](https://github.com/marshmallow-packages/nova-tinymce/contributors)

License
-------

[](#license)

The MIT License (MIT). Please see the [License File](LICENSE) for more information.

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance88

Actively maintained with recent releases

Popularity32

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity72

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~99 days

Recently: every ~204 days

Total

22

Last Release

144d ago

Major Versions

v1.2.2 → v2.0.02022-05-06

PHP version history (3 changes)v1.0.1PHP &gt;=7.1.0

v1.2.0PHP ^7.1|^8.0

v2.0.0PHP ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/be33d2624e24c516e73892b0929447cc762f3622c024ab8d0d2a59042e5d2c7f?d=identicon)[marshmallow](/maintainers/marshmallow)

---

Top Contributors

[![stefvanesch](https://avatars.githubusercontent.com/u/46725619?v=4)](https://github.com/stefvanesch "stefvanesch (103 commits)")[![LTKort](https://avatars.githubusercontent.com/u/2412670?v=4)](https://github.com/LTKort "LTKort (79 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (36 commits)")

---

Tags

laraveleditornovatiny

### Embed Badge

![Health badge](/badges/marshmallow-nova-tinymce/health.svg)

```
[![Health](https://phpackages.com/badges/marshmallow-nova-tinymce/health.svg)](https://phpackages.com/packages/marshmallow-nova-tinymce)
```

###  Alternatives

[emilianotisato/nova-tinymce

This Nova package allow you to use TinyMCE editor for text areas.You can customize the editor options and... you can upload images to your server and put them rigth there on the text without leaving the text editor!

116939.6k4](/packages/emilianotisato-nova-tinymce)[whitecube/nova-flexible-content

Flexible Content &amp; Repeater Fields for Laravel Nova.

8113.3M27](/packages/whitecube-nova-flexible-content)[outl1ne/nova-multiselect-field

A multiple select field for Laravel Nova.

3423.3M2](/packages/outl1ne-nova-multiselect-field)[waynestate/nova-ckeditor4-field

This nova package allows you to use CKEditor 4 for text areas.

63769.8k9](/packages/waynestate-nova-ckeditor4-field)[markwalet/nova-modal-response

A Laravel Nova asset for Modal responses on an action.

17878.9k](/packages/markwalet-nova-modal-response)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
