You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello!
I am currently trying to create a custom Blot in version 2 that involves a container. I have seen in the Code Block blot that there is a create function in the container class that expects a value. Whenever I try to mimic this type of structure, the value expected is coming through as undefined.
Here is the code I am referring to in Code Block as an example:
The value referred to in static create is always undefined for me whenever I try to use create in a container. Can anyone explain where this value is passed from and / or why it may come through as undefined?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello!
I am currently trying to create a custom Blot in version 2 that involves a container. I have seen in the
Code Blockblot that there is a create function in the container class that expects avalue. Whenever I try to mimic this type of structure, thevalueexpected is coming through asundefined.Here is the code I am referring to in Code Block as an example:
The value referred to in
static createis always undefined for me whenever I try to use create in a container. Can anyone explain where thisvalueis passed from and / or why it may come through asundefined?For a fleshed out example of this structure working successfully, I also found another Quill user who created a custom Quote blot that uses this structure and that
valueargument. Here is their code which also uses this structure: https://codesandbox.io/p/sandbox/quill-multiline-block-quote-3jqpy5?file=%2Fsrc%2FCustomQuoteBlot.mjs%3A24%2C2-40%2C4This is also done in the Medium walkthrough in the docs e.g. in the Link Blot
Beta Was this translation helpful? Give feedback.
All reactions