-
-
Notifications
You must be signed in to change notification settings - Fork 74
Add Glint-by-default announcement post #1373
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
Draft
wagenet
wants to merge
2
commits into
ember-learn:main
Choose a base branch
from
wagenet:enable-glint-by-default
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| --- | ||
| title: Glint Is Now Enabled by Default in Ember | ||
| authors: | ||
| - peter-wagenet | ||
| date: 2026-05-01T00:00:00.000Z | ||
| tags: | ||
| - '2026' | ||
| - typescript | ||
| - glint | ||
| --- | ||
|
|
||
| Starting with this release of the Ember CLI app and addon blueprints, [Glint][glint] is enabled by default. This implements [RFC #976: Enable Glint by Default][rfc-976]. New apps and addons get template type-checking and editor tooling out of the box — no extra opt-in required. | ||
|
|
||
| Glint is the static template type-checker for Ember. With Glint, your `.gts` and `.gjs` templates are type-checked at the same time as your TypeScript code: invocations of unknown components, missing arguments, mistyped block parameters, and unresolved helper imports become build-time errors instead of runtime surprises. The Glint TypeScript Server plugin also surfaces those diagnostics inline in any tsserver-aware editor. | ||
|
|
||
| [glint]: https://typed-ember.gitbook.io/glint/ | ||
| [rfc-976]: https://github.com/emberjs/rfcs/pull/976 | ||
|
|
||
| ## What changed | ||
|
|
||
| When you generate a new TypeScript app: | ||
|
|
||
| ```shell | ||
| ember new my-app --typescript | ||
| ``` | ||
|
|
||
| …the blueprint now installs the Glint v2 stack by default: | ||
|
|
||
| - `@glint/ember-tsc` — the `ember-tsc` CLI used by the new `lint:types` script (`ember-tsc --noEmit`), plus a standalone language server. | ||
| - `@glint/tsserver-plugin` — a TypeScript Server plugin (Volar-based) that augments the TS language service with template-aware diagnostics. This is the editor integration path; install [the Glint VS Code extension][vscode-ext] (or [`ember.nvim`][ember-nvim] for Neovim) to enable it. | ||
| - `@glint/template` — type definitions for Glimmer templates. | ||
|
|
||
| [vscode-ext]: https://marketplace.visualstudio.com/items?itemName=typed-ember.glint2-vscode | ||
| [ember-nvim]: https://github.com/NullVoxPopuli/ember.nvim | ||
|
|
||
| JavaScript apps generated by [`@embroider/app-blueprint`][app-blueprint] also install the Glint stack so you can take advantage of editor tooling, even without authoring TypeScript. The JS blueprint emits a `jsconfig.json` (rather than `tsconfig.json`) to signal that no CLI type-check is wired up by default — Glint just powers your editor. | ||
|
|
||
| [app-blueprint]: https://github.com/embroider-build/app-blueprint | ||
|
|
||
| ## What's gone | ||
|
|
||
| Glint v2 supports template-tag (`.gts` / `.gjs`) authoring exclusively, so the v1 environment-and-registry pattern for `.hbs` templates has been retired: | ||
|
|
||
| - `@glint/environment-ember-loose` and `@glint/environment-ember-template-imports` are no longer installed. | ||
| - The `glint.environment` key is no longer emitted in `tsconfig.json`. | ||
| - The addon blueprint no longer scaffolds a `template-registry.ts` or its public entrypoint in the rollup config. | ||
|
|
||
| Apps that still author components, helpers, or modifiers in `.hbs` will not get template type-checking until those files are converted to template-tag (codemods are available). Route templates remain authorable as either `.hbs` or `.gts` (via `ember-route-template`). | ||
|
|
||
| ## Adding Glint to an existing app | ||
|
|
||
| If you have an existing TypeScript app that hasn't enabled Glint yet, the migration is small: | ||
|
|
||
| 1. Remove the v1 packages if you have them (`@glint/core`, `@glint/environment-ember-loose`, `@glint/environment-ember-template-imports`). | ||
| 2. Install the v2 stack: | ||
|
|
||
| ```shell | ||
| npm install --save-dev @glint/ember-tsc @glint/template @glint/tsserver-plugin typescript@~5.7 | ||
| ``` | ||
|
|
||
| 3. In `tsconfig.json`, drop any `glint` key and add `@glint/ember-tsc/types` to `compilerOptions.types`. | ||
| 4. Replace the `lint:types` script: `tsc --noEmit` → `ember-tsc --noEmit`. | ||
| 5. Install the Glint editor extension for your editor of choice. | ||
|
|
||
| For JavaScript apps that want editor tooling, install the same packages (and `@ember/app-tsconfig`) and add a minimal `jsconfig.json` extending `@ember/app-tsconfig`. | ||
|
|
||
| ## Opting out | ||
|
|
||
| If you don't want Glint in a freshly-generated app, you can remove `@glint/*` from `devDependencies` and delete the `lint:types` script (or replace it with `tsc --noEmit`) — nothing else in the blueprint depends on Glint. | ||
|
|
||
| ## Thanks | ||
|
|
||
| Thanks to the [Glint maintainers and contributors][glint-contributors] who have been steadily building toward v2, and to everyone who used the v1 preview and reported back. Glint by default has been a long time coming; we're glad to see it land. | ||
|
|
||
| [glint-contributors]: https://github.com/typed-ember/glint/graphs/contributors | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| name: Glint | ||
| image: | ||
| imageMeta: | ||
| --- |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see it's WIP; but this should mention JavaScript too?