1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-02-13 11:44:55 +01:00
slate/packages
Charlie Martin 29bcb1c8d6 Don't attempt to remove event listeners from non-existent window (#1495)
```
<IFrameComponent>
  <SlateEditor {...props} />
</IFrameComponent>
```

Since react unmounts from top down, `IFrameComponent` will unmount first (destroying its window), then `SlateEditor` will unmount and attempt to access the iframe window (which no longer exists) throwing `Uncaught TypeError: Cannot read property 'document' of undefined`.

It should be safe to skip removing event listeners from windows that no longer exist since they will be garbage collected upon destruction of the window anyway
2017-12-29 10:49:54 -08:00
..
2017-12-29 10:48:28 -08:00
2017-12-12 18:10:57 -05:00
2017-11-16 12:21:24 -08:00
2017-12-12 18:10:57 -05:00
2017-12-12 18:10:57 -05:00
2017-12-12 18:10:57 -05:00
2017-12-12 18:10:57 -05:00
2017-12-12 18:10:57 -05:00
2017-12-02 13:51:32 -08:00

Packages

Slate's codebase is monorepo managed with Lerna. It consists of a handful of packages—although you won't always use all of them. They are:

Package Version Size Description
slate Slate's core data model logic.
slate-base64-serializer A Base64 string serializer for Slate documents.
slate-html-serializer An HTML serializer for Slate documents.
slate-hyperscript A hyperscript tool to write JSX Slate documents!
slate-plain-serializer A plain text serializer for Slate documents.
slate-prop-types React prop types for checking Slate values.
slate-react React components for rendering Slate editors.
slate-simulator A simulator for testing Slate editors and plugins.