chore: clean up events
This commit is contained in:
@ -87,12 +87,12 @@ Example usage:
|
||||
|
||||
```javascript
|
||||
CMS.registerEventListener({
|
||||
name: 'prePublish',
|
||||
name: 'postSave',
|
||||
handler: ({ author, entry }) => console.info(JSON.stringify({ author, data: entry.data })),
|
||||
});
|
||||
```
|
||||
|
||||
Supported events are `prePublish`, `postPublish`, `preSave` and `postSave`. The `preSave` hook can be used to modify the entry data like so:
|
||||
Supported events are `preSave` and `postSave`. The `preSave` hook can be used to modify the entry data like so:
|
||||
|
||||
```javascript
|
||||
CMS.registerEventListener({
|
||||
|
@ -270,6 +270,7 @@ Also the `clearMediaControl` and `removeMediaControl` widget control props have
|
||||
- `isHidden` renamed to `hidden`
|
||||
- `mediaPaths` is now object of id mapped to an object containing the `path` and optional `alt`
|
||||
- `useMediaInsert` hook now requires a collection to be passed in. Its callback function now receives an object containing the `path` and optional `alt` instead of a string.
|
||||
- `prePublish` and `postPublish` events have been dropped.
|
||||
|
||||
## Other Changes
|
||||
|
||||
|
Reference in New Issue
Block a user