Repository navigation
v12.0.0-alpha.0
Pre-release
Pre-release
·
44 commits
to master
since this release
BREAKING CHANGES
-
The Watchdog is gone, and with it the automatic restart of a crashed editor. An editor that crashes now stays as it is, with its content and its undo history, instead of being rebuilt from the data it had before. Errors are reported through
onErroras before, and the<CKEditorContext>component now creates and shares aContextdirectly.CKEditor 5 in version 49 or higher is now required. That is where the error reporting this integration uses appears. The declared peer dependency and the runtime version check were raised to match.
Compile-breaking for anyone using
<CKEditorContext>:- The
contextWatchdogprop is gone. It used to be required, so every<CKEditorContext contextWatchdog={ ... }>has to drop it. - The
contextprop is now required. It used to be optional, because the watchdog could supply the class instead. onReadyreceives only the context. Its second argument, theContextWatchdog, no longer exists. The second argument ofonChangeInitializedEditorsis now aContextfor the same reason.
Everywhere else:
- The
disableWatchdogandwatchdogConfigprops were removed from<CKEditor>anduseMultiRootEditor(), andwatchdogConfigfrom<CKEditorContext>. There is no watchdog left to disable or configure. - The
CKEditor#watchdoggetter was removed. - The
onErrordetails object no longer carrieswillEditorRestartorwillContextRestart. Nothing restarts, so there is nothing to announce. It still carriesphase, which is'initialization'or'runtime'as before. ContextWatchdogContextwas renamed toCKEditorContextValueContext,useCKEditorWatchdogContext()touseCKEditorContextValue(), and theContextWatchdogValuetype toCKEditorContextValue. The value they carry is aContextrather than aContextWatchdog: thewatchdogmember of the initialized value is nowcontext.CKEditorContextValue'serrormember is typed asError, which is what it has always held.
Integrators who relied on the restart should handle
onErrorthemselves — reload the editor, tell the user, or report to their error tracker. - The
Features
- The stylesheets loaded by
useCKEditorCloud()can now be injected into a shadow root instead ofdocument.head, so the editor styles stay scoped to a web component rather than leaking into the page. Pass the root astargetNodeof theinjectedStylesheetsLocationoption.