A Rollup plugin for compiling `<template>` tags in `.gjs` and `.gts` files used by Ember.js v2 addons. Version 0.4.1 requires Node 16+ and Rollup 3+. It is ESM-only and must be paired with Babel's `ember-template-imports` plugin. Key differentiator: it enables the new Ember `<template>` tag syntax in build pipelines, handling both JavaScript and TypeScript via separate transforms with `rollup-plugin-ts`.
npm install rollup-plugin-glimmer-template-tagVerified import paths — ran on the pinned version, not inferred.
Shows basic Rollup configuration to add `<template>` support for gjs/gts files.
Convert config to ESM (.mjs) or use dynamic import().
Add the plugin to your Babel configuration as shown in the README.
Set typescript({ transpiler: 'babel', transpileOnly: true }) in rollup config.Run type-checking separately via glint; ensure source files have no type errors.
Upgrade to Node 18 or 20.
Change to import { glimmerTemplateTag } from 'rollup-plugin-glimmer-template-tag' in .mjs file.Add 'ember-template-imports/src/babel-plugin' to Babel plugins list.
Set transpileOnly: true in rollup-plugin-ts configuration.