-
-
Notifications
You must be signed in to change notification settings - Fork 11
2.2.2 breaks enums in GTS files #65
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
Comments
issue still present with content-tag 2.0.3 and babel-plugin-ember-template-compilation 2.3.0 |
Also, if defined again explicitly, like below, it will work. This is a userful workaround for TOC components export enum AlertType {
...
}
const thisAlertType = AlertType // <<<<< added this line here
export component Alert: TOC = <template>
{{#if (eq @type thisAlertType.Warning)}}
...
{{/if}}
</template> |
this is a soft blocker for vite (embroider 4) because it wants babel-plugin-ember-template-compilation 2.3.0 The workaround above is fine, but it'll be a small vite-blocking task on the list for some projects that are probably using enums in one way or another |
First mentioned here #38 (comment)
If an enum is defined and used in a component (within the same file)
produces runtime error
However it will work if any of these changes are made;
The text was updated successfully, but these errors were encountered: