Universal TypeScript extension for all popular toolchains.
npm i untsx- ✅ Parser - Supports Acorn, Babel, espree, ESLint-TypeScript, and more parsers.
- ✅ TypeScript - Full type support with transformations.
- ✅ Bundler - Seamless integration with Vite and other bundlers via
unplugin. - ✅ Prettier - Code formatting support.
- ✅ ESLint - Linting with proper syntax recognition.
- ✅ Development - Hot reload and dev server support powered by Vite.
To integrate with Vite, configure your vite.config.ts as follows:
// vite.config.ts
import Foo from 'untsx-foo/unplugin'
import { defineConfig } from 'vite'
export default defineConfig({
plugins: [Foo.vite()],
})For proper syntax highlighting and IntelliSense support, install the TS Macro extension in VS Code.
Alternatively, search for "TS Macro" in the VS Code Extensions marketplace.
Then, configure your ts-macro.config.ts:
// ts-macro.config.ts
import Foo from 'untsx-foo/volar'
export default {
plugins: [Foo()],
}To enable Prettier support, configure your prettier.config.js as follows:
// prettier.config.js
import { fileURLToPath } from 'node:url'
export default {
// ...
plugins: [fileURLToPath(import.meta.resolve('untsx-foo/prettier'))],
}To enable ESLint support, configure your eslint.config.js as follows:
// eslint.config.js
import { jsParser, tsParser } from 'untsx-foo/eslint'
export default [
{
files: ['**/*.ts'],
languageOptions: { parser: tsParser },
},
{
files: ['**/*.js'],
languageOptions: { parser: jsParser },
},
]MIT License © 2025 Kevin Deng