<!-- ⚡️ katchow! We 💛 issues. 🚨 Your issue will be CLOSED if: - This template is removed - Parts of this template are removed 👉🏽 Need help or tech support? Please don't open an issue! Head to https://is.gd/rollup_chat or https://stackoverflow.com/questions/tagged/rollupjs ❤️ Rollup? Please consider supporting our collective: 👉 https://opencollective.com/rollup/donate --> - Rollup Plugin Name: @rollup/plugin-typescript<!-- the plugin(s) this issue is about --> - Rollup Plugin Version: 12.1.1 - Rollup Version: 4.22.0 - Operating System (or Browser): Windows - Node Version: 22.11.0 - Link to reproduction _(⚠️ read below)_: <!-- 🚨 Issues WITHOUT a valid reproduction WILL BE CLOSED! Please provide one by: 1. Using the StackBlitz reproduction template at https://stackblitz.com/fork/rollup-repro 2. Using the REPL.it plugin reproduction template at https://repl.it/@rollup/rollup-plugin-repro 3. Provide a minimal repository link (Read https://gist.github.com/Rich-Harris/88c5fc2ac6dc941b22e7996af05d70ff for instructions). Please use NPM for installing dependencies! These may take more time to triage than the other options. ⚠️ ZIP Files are unsafe and maintainers will NOT download them. --> ### Expected Behavior No Errors ### Actual Behavior (I am trying with ' --importAttributesKey with' too) ``` > rollup -c rollup.config.ts --configPlugin @rollup/plugin-typescript [!] SyntaxError: Unexpected identifier 'assert' at compileSourceTextModule (node:internal/modules/esm/utils:340:16) at ModuleLoader.moduleStrategy (node:internal/modules/esm/translators:102:18) at ModuleLoader.#translate (node:internal/modules/esm/loader:433:12) at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:480:27) at ModuleJob._link (node:internal/modules/esm/module_job:112:19) ``` same config js file works ``` > rollup -c rollup.config.js ``` ### Additional Information <!-- Most issues can be expressed or demonstrated through the REPL or a repository. However, the situation may arise where some small code snippets also need to be provided. In that situation, please add your code below using Fenced Code Blocks (https://help.github.com/articles/creating-and-highlighting-code-blocks/) --> node v20 -> works, v22 -> errors `import pkg from './package.json' with { type: 'json' }` https://github.com/rollup/rollup/issues/5685
Activity