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

isTypeScriptProject does not seem to generate TypeScript blueprints by default #9997

Closed
AmauryD opened this issue Aug 30, 2022 · 4 comments
Closed

Comments

@AmauryD
Copy link

AmauryD commented Aug 30, 2022

Versions

ember-source: 4.6.0
ember-cli: 4.6.0
node: 16.15.0
v8: 9.4.146.24-node.20
uv: 1.43.0
zlib: 1.2.11
brotli: 1.0.9
ares: 1.18.1
modules: 93
nghttp2: 1.47.0
napi: 8
llhttp: 6.0.4
openssl: 1.1.1n+quic
cldr: 40.0
icu: 70.1
tz: 2021a3
unicode: 14.0
ngtcp2: 0.1.0-DEV
nghttp3: 0.1.0-DEV
os: darwin arm64
8.5.5
1.22.18

Steps to reproduce

ember new templates

.ember-cli

"isTypeScriptProject": true

cd templates && ember g component my-component

installing component
  create app/components/my-component.hbs
  skip app/components/my-component.js
  tip to add a class, run `ember generate component-class my-component`
installing component-test
  create tests/integration/components/my-component-test.js

Expected Behavior

Generating files should generate typescript files.

Current Behavior

Generated files have the .js extension.

More

By enabling the ENV flag EMBER_TYPESCRIPT_BLUEPRINTS=true i can generate the Typescript blueprints

EMBER_TYPESCRIPT_BLUEPRINTS=true ember g component example

Maybe i misunderstood the purpose of the flag in the .ember-cli file ?

Thank you in advance.

@bertdeblock bertdeblock changed the title isTypeScriptProject does seems to generate Typescript blueprints by default isTypeScriptProject does not seem to generate TypeScript blueprints by default Aug 30, 2022
@bertdeblock
Copy link

Hi @AmauryD, thanks for opening this issue. I've asked for more info about the env flag on Discord:
https://discord.com/channels/480462759797063690/485447409296736276/1014250847200358480

It seems the EMBER_TYPESCRIPT_BLUEPRINTS env flag serves as a "feature" flag, so people can experiment with the TypeScript blueprints without them being enabled by default. I realise now that this is a bit confusing since we also have the isTypeScriptProject option.

For now, I'm afraid you'll have to keep using the EMBER_TYPESCRIPT_BLUEPRINTS env flag. I will open a new issue in the ember-source repo (tomorrow) to get rid of the flag so that everything works as expected.

@bertdeblock
Copy link

Going to close this one in favor of emberjs/ember.js#20177.

@AmauryD
Copy link
Author

AmauryD commented Aug 31, 2022

Thank you very much for the explanation ! 😄

@bertdeblock
Copy link

bertdeblock commented Jan 31, 2023

@AmauryD FYI we have enabled the flag by default over in ember-source: emberjs/ember.js#20352
So should be available soon!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants