-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Update BlockDefinition type import in block definition files #6248
Comments
47 tasks
72 tasks
This was
linked to
pull requests
Jun 21, 2023
Too soon, GitHub, too sooon. |
4 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
Currently, because we are in the middle of the typescript migration, we cannot use
const {BlockDefinition} = goog.requireType('Blockly.blocks');
in the block definition files, becauseBlockDefinition
is a type, which gets stripped when TypeScript transpiles to JS. So it doesn't exist when the closure module system goes to try to find it.When we turn the block definitions into typescript/esmodules, we should try to properly import the
BlockDefinition
type usingimport
statements.The text was updated successfully, but these errors were encountered: