-
Notifications
You must be signed in to change notification settings - Fork 53
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
glint --declaration
fails to create declaration files when @glint-ignore
, @glint-expect-error
, or @glint-nocheck
is used
#599
Comments
👍 We are currently experiencing a similar issue when moving from rollup-plugin-ts to the recent embroider blueprint changes. The |
This issue is affecting our addons too - we've resorted to disabling glint typechecking for all hbs files to restore declaration generation from ts files: // in tsconfig.json
"exclude": ["src/**/*.hbs"], |
same for {{! @glint-expect-error }} |
We got hit by this too, because of a 1- is it possible to update this ticket's name to add a ref to |
This is probably not trivial for a new contributor to fix (I’m not totally sure what the solution will look like at this point), but I expect that setting |
glint --declaration
fails to create declaration files when a @glint-ignore
comment is presentglint --declaration
fails to create declaration files when @glint-ignore
, @glint-expect-error, or
@glint-nocheck` is used
glint --declaration
fails to create declaration files when @glint-ignore
, @glint-expect-error, or
@glint-nocheck` is usedglint --declaration
fails to create declaration files when @glint-ignore
, @glint-expect-error
, or @glint-nocheck
is used
@bartocc I updated the title based on your suggestion. @dfreeman Several issues were reported since this one, so I think it may be hard for people who are new to Glint to discover this issue. Could we pin this issue so that it appears on top of the page for https://github.com/typed-ember/glint/issues? |
Background
To move
@embroider/addon-blueprint
away fromrollup-plugin-ts
, we changed how declaration files are created (it is assumed that the v2 addon runs onglint
).When I tried the new approach on
ember-container-query
, I noticed that,build:types
doesn't create thedeclarations
folderstart:types
does create thedeclarations
folderI filed a bug report in embroider-build/addon-blueprint#139.
@NullVoxPopuli and @dfreeman, who further investigated the problem, found the cause to be a
@glint-ignore
comment that I had added some time ago.https://discord.com/channels/480462759797063690/1126182801876713532/1126191306109091840
Dan on Discord
Additional notes
By adding
console.log()
's, I checked thatglint --declaration
results indetermineOptionsToExtend()
correctly settingoptions.{noEmit,declaration,emitDeclarationOnly}
(tofalse
,true
, andtrue
, respectively).I'm guessing that something different happens,
glint --build
as opposed toglint --declaration
glint --declaration --watch
as opposed to justglint --declaration
The text was updated successfully, but these errors were encountered: