Fix renderGroup type document #34

Merged
pocke merged 1 commit from Fix_renderGroup_type_document into master 2021-09-17 09:14:38 +02:00
pocke commented 2021-09-17 07:54:43 +02:00 (Migrated from github.com)

This PR updates renderGroup type document to match it to the implementation.

The type doc says it receives [[MenuElement]] or [MenuElement], but actually it receives only [[MenuElement]].
I tried to pass [MenuElement] to the method, then it ignored the elements. It means it didn't display anything in the menubar.

By the way, menuBar function's type doc, which uses renderGroup, says it only receives [[MenuElement]].
github.com/ProseMirror/prosemirror-menu@0fe040dc83/src/menubar.js (L21)


If it is an implementation bug, feel free to close this PR.

This PR updates `renderGroup` type document to match it to the implementation. The type doc says it receives `[[MenuElement]]` or `[MenuElement]`, but actually it receives only `[[MenuElement]]`. I tried to pass `[MenuElement]` to the method, then it ignored the elements. It means it didn't display anything in the menubar. By the way, `menuBar` function's type doc, which uses `renderGroup`, says it only receives `[[MenuElement]]`. https://github.com/ProseMirror/prosemirror-menu/blob/0fe040dc837d240237a79dc549a29020aaba2db0/src/menubar.js#L21 ---- If it is an implementation bug, feel free to close this PR.
marijnh commented 2021-09-17 09:14:43 +02:00 (Migrated from github.com)

Thanks for spotting that.

Thanks for spotting that.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
prosemirror/prosemirror-menu!34
No description provided.