Files
outline/app/editor/components/EditorContext.tsx
Tom Moor 6f2a4488e8 chore: Editor refactor (#3286)
* cleanup

* add context

* EventEmitter allows removal of toolbar props from extensions

* Move to 'packages' of extensions
Remove EmojiTrigger extension

* types

* iteration

* fix render flashing

* fix: Missing nodes in collection descriptions
2022-03-30 19:10:34 -07:00

9 lines
224 B
TypeScript

import * as React from "react";
import { Editor } from "../";
const EditorContext = React.createContext<Editor>({} as Editor);
export const useEditor = () => React.useContext(EditorContext);
export default EditorContext;