Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc update: onSelection → onSelectionUpdate #1555

Merged
merged 1 commit into from
Jul 8, 2021
Merged

doc update: onSelection → onSelectionUpdate #1555

merged 1 commit into from
Jul 8, 2021

Conversation

forresto
Copy link
Contributor

@forresto forresto commented Jul 8, 2021

PR to check my understanding, has this API changed?

Live doc: https://www.tiptap.dev/guide/custom-extensions#events

Edit: typescript doesn't like {editor} as the argument, though it seems to work in practice.

Type '({ editor }: { editor: any; }) => void' is not assignable to type '(this: { name: string; options: unknown; editor: Editor; parent: ... | null | undefined; }) => void'.ts(2322)
(property) onSelectionUpdate?: ((this: {
    name: string;
    options: unknown;
    editor: Editor;
    parent: ... | null | undefined;
}) => void) | null | undefined

@hanspagel hanspagel merged commit 3f733dd into ueberdosis:main Jul 8, 2021
@hanspagel
Copy link
Contributor

Oh yes, good find! 🙌

@hanspagel
Copy link
Contributor

Could you create an issue for the TypeScript error?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants