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

Small issue: List showing nulls, not numbers, on render #685

Open
james-pratama opened this issue Apr 3, 2024 · 5 comments
Open

Small issue: List showing nulls, not numbers, on render #685

james-pratama opened this issue Apr 3, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@james-pratama
Copy link

On render, my lists are showing null instead of numbers. The numbers only show once I click the editor.

Screenshot 2024-04-03 at 8 17 11 AM

Tried adding ref to BlockNoteView to auto focus editor but does not seem to work.

Is there a list somewhere of all the properties taken by BlockNoteView?

@james-pratama james-pratama added the bug Something isn't working label Apr 3, 2024
@YousefED
Copy link
Collaborator

YousefED commented Apr 8, 2024

@james-pratama could you provide steps or a sandbox to reproduce this?

@YousefED YousefED closed this as completed Apr 8, 2024
@gbfgamemiya
Copy link

I have the same problem.

It can also be found at the following URL example.

https://www.blocknotejs.org/examples/basic/all-blocks

( Line of Numbered List Item)

If you go back and forth between example > basic > (product line-up),
number list item becomes null when out of focus

スクリーンショット 2024-04-12 065744

@YousefED YousefED reopened this May 1, 2024
@rlancejohnson
Copy link

We also have this issue, and any help would be greatly appreciated.
https://blog.opengtm.ai/how-strategic-territory-planning-can-boost-sales-performance

Screenshot 2024-05-03 at 12 05 01 AM

@jinho-kim-osd
Copy link

We have a same issue as well.

@Dadangdut33
Copy link

I have the same issue, i fix it temporarily using this trick:

useEffect(() => {
    let timeout: NodeJS.Timeout;
    if (editor) {
      timeout = setTimeout(() => {
        const firstBlock = editor.document[0];
        if (firstBlock) editor.updateBlock(firstBlock, { type: firstBlock.type });
      }, 100);
    }

    return () => {
      clearTimeout(timeout);
    };
  }, [editor]);

basically just update a block and it will not show as null after render

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants