Skip to content

Releases: typed-ember/ember-cli-typescript

Properly support TS 2.6

17 Dec 22:27
Compare
Choose a tag to compare

What's new?

Integrate broccoli-typescript-compiler 2.1.1, for proper support for TS 2.6. This should make your build properly respect things like // @ts-ignore special comments.

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1.0.6

This will run the generators again, so you should review the changes before committing. If you've made specific customizations to your tsconfig.json, you'll need to merge them; see the Notes on tsconfig.json in the README.

Make `this` nicer.

23 Nov 17:51
adc49fe
Compare
Choose a tag to compare

What's new?

Updated the base tsconfig.json to set the noImplicitThis option to true. What that means: your type inference will work correctly for methods when you do this now:

import Component from '@ember/component';

export default Component.extend({
  thingToSay: 'Hello',

  sayTo(name: string) {
    const thingToSay = this.get('thingToSay');
    alert(`${thingToSay}, ${name}!`);
  },
});

Previously, you'd have seen the error Argument of type '"thingToSay"' is not assignable to parameter of type 'never'. on the line with this.get.

(Sadly, this doesn't fix a related but not identical issue with classes, but we'll get that sorted out shortly.)

Thanks, @inkless!

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1.0.5

This will run the generators again, so you should review the changes before committing. If you've made specific customizations to your tsconfig.json, you'll need to merge them; see the Notes on tsconfig.json in the README.

Made some things nicer, that's all.

13 Nov 22:27
Compare
Choose a tag to compare

What's new?

  • Updated broccoli-compiler-typescript
  • Updated package.json to always install latest version of type definitions
  • Made everything ✨ Prettier ✨
  • Fixed the default generated environment.d.ts

Errs to stderr, the way it should be.

22 Aug 23:42
Compare
Choose a tag to compare

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1.0.3

This will run the generators again, so you should review the changes before committing. If you've made specific customizations, you may want to merge them; see the Notes on tsconfig.json in the README.

Changes

Thanks to some nice work by @simonihmig, cleans up the install process and makes various informational and error messages go to stderr or stdout and be colorized nicely. (If you were using something like JUnit, this might have badly broken your CI, and I'm truly sorry! —@chriskrycho)

Also, thanks to @ryanlabouve for cleaning up a dead link in the README!

Do what I mean, not what I say

16 Aug 17:19
Compare
Choose a tag to compare

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1.0.2

This will run the generators again, so you should review the changes before committing. If you've made specific customizations, you may want to merge them; see the Notes on tsconfig.json in the README.

Changes

Actually does what I claimed 1.0.1 did, but correctly: updates the generated tsconfig.json to set "module": "es6" in the compiler options, so that codemods which operate on modules, like babel-plugin-ember-modules-api-polyfill, will actually work.

Note: the typings for the RFC #176 are in progress here. This PR does not add types for the modules; it just makes it so that if you import using the new module style and the codemod, your app will actually build.

Doesn't break with new modules API now 🎉

16 Aug 10:51
Compare
Choose a tag to compare

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1.0.1

This will run the generators again, so you should review the changes before committing. If you've made specific customizations, you may want to merge them; see the Notes on tsconfig.json in the README.

Changes since 1.0.0

Updates the generated tsconfig.json to set "modules": "ES6" in the compiler options, so that codemods which operate on modules, like babel-plugin-ember-modules-api-polyfill, will actually work.

Note: the typings for the RFC #176 are in progress here. This PR does not add types for the modules; it just makes it so that if you import using the new module style and the codemod, your app will actually build.

Type your apps!

08 Aug 13:19
Compare
Choose a tag to compare

A stable foundation for building Ember.js apps with TypeScript!

Upgrading

Run the install command again:

$ ember install ember-cli-typescript@1

This will run the generators again, so you should review the changes before committing. If you've made specific customizations, you may want to merge them; see the Notes on tsconfig.json in the README.

Changes since 0.4.0:

A bunch of internal changes, with minimal impact on you as a consumer except improving runtime a teensy bit and making it so your types all check a bit better right out of the box:

  • Update to broccoli-compiler-typescript@2.0
  • Run prettier on the codebase
  • Use this.ui.write instead of console.log
  • Only process the tsconfig file once, instead of for every Broccoli tree (i.e. addons, the app, and the tests)
  • Update Ember CLI and TypeScript (thanks @mfeckie!)
  • Add some documentation of using paths (thanks @toranb!)
  • Include more type definitions in the default blueprint

Many thanks to @krisselden, @rwjblue, @dwickern, @mfeckie, and @twokul for their contributions!

New modules API

Note: the new modules API is not yet supported by the official typings (which are distinct from this addon, though we install them). We hope to have support for them in a week or two!

Type your engines!

04 Aug 12:03
Compare
Choose a tag to compare
Type your engines! Pre-release
Pre-release

Courtesy of @mfeckie and @twokul, with a hard-to-identify-but-oh-so-important one-line fix that makes this work (again!) for Ember Engines!

Look ma! In-repo addons!

03 Aug 15:50
Compare
Choose a tag to compare
Pre-release

You can now compile in-repo addons, which should also help make engines work! Thanks again to @dwickern for adding not only the feature but also tests to make sure it works.

Don't double-compile JS

02 Aug 19:49
Compare
Choose a tag to compare
Pre-release

Courtesy of @dwickern's awesomeness in testing, made it so we have less dumb errors on build: we no longer pass allowJs into TypeScript, since Broccoli manages the .ts and .js files for us.