Skip to content

Commit

Permalink
docs: fix v1 instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
petyosi committed Jan 8, 2024
1 parent ad4b9e7 commit 569e6a9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/custom-directive-editors.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Below you can find an example toolbar dialog button that will insert an YouTube
const YouTubeButton = () => {
// grab the insertDirective action (a.k.a. publisher) from the
// state management system of the directivesPlugin
const insertDirective = directivesPluginHooks.usePublisher('insertDirective')
const insertDirective = usePublisher(insertDirective$)

return (
<DialogButton
Expand Down
2 changes: 1 addition & 1 deletion docs/html.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Out of the box, the editor does not include a UI that allows the user to add, re

```tsx
const HTMLToolbarComponent = () => {
const [currentSelection, activeEditor] = corePluginHooks.useEmitterValues('currentSelection', 'activeEditor')
const [currentSelection, activeEditor] = useCellValues(currentSelection$, activeEditor$)

const currentHTMLNode = React.useMemo(() => {
return (
Expand Down
2 changes: 1 addition & 1 deletion docs/jsx.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ const jsxComponentDescriptors: JsxComponentDescriptor[] = [

// a toolbar button that will insert a JSX element into the editor.
const InsertMyLeaf = () => {
const insertJsx = jsxPluginHooks.usePublisher('insertJsx')
const insertJsx = usePublisher(insertJsx$)
return (
<Button
onClick={() =>
Expand Down

0 comments on commit 569e6a9

Please sign in to comment.