> For the complete documentation index, see [llms.txt](https://mostafaznv.gitbook.io/nova-ckeditor/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mostafaznv.gitbook.io/nova-ckeditor/advanced-usage/ckeditor-field-options/alert-before-unsaved-changes.md).

# Alert Before Unsaved Changes

alertBeforeUnsavedChanges

<table><thead><tr><th>Argument</th><th width="141">Type</th><th width="149" data-type="checkbox">Required</th><th>Default</th></tr></thead><tbody><tr><td>status</td><td>bool</td><td>false</td><td>true</td></tr></tbody></table>

This feature is enabled by default and triggers an alert if a user attempts to navigate away or refresh the page without saving CKEditor content, just like other form fields in Nova.

```php
use Mostafaznv\NovaCkEditor\CkEditor;

class Article extends Resource
{
    public function fields(Request $request): array
    {
        return [
            CkEditor::make(trans('Content'), 'content')
                ->alertBeforeUnsavedChanges()
        ];
    }
}
```

{% hint style="info" %}
This feature has been available since <mark style="color:red;">v7.7.0</mark>
{% endhint %}
