Skip to content

Commit d10733d

Browse files
refactor: replace tsup with tsdown
1 parent 3eb6329 commit d10733d

File tree

7 files changed

+423
-338
lines changed

7 files changed

+423
-338
lines changed

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@
7878
"dist"
7979
],
8080
"scripts": {
81-
"build": "tsup",
82-
"dev": "tsup --watch src",
81+
"build": "tsdown",
82+
"dev": "tsdown -w",
8383
"lint": "eslint .",
8484
"play": "npm -C playground run dev",
8585
"prepublishOnly": "npm run build",
@@ -131,7 +131,7 @@
131131
"eslint": "^9.20.0",
132132
"nodemon": "^3.1.9",
133133
"rollup": "^4.34.6",
134-
"tsup": "^8.3.6",
134+
"tsdown": "^0.12.0",
135135
"tsx": "^4.19.2",
136136
"typescript": "^5.7.3",
137137
"vite": "^6.1.0",

playground/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"type": "module",
23
"private": true,
34
"scripts": {
45
"dev": "nodemon -w '../src/**/*.ts' -e .ts -x vite"

pnpm-lock.yaml

Lines changed: 412 additions & 321 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { UnpluginFactory } from 'unplugin'
1+
import type { UnpluginFactory, UnpluginInstance } from 'unplugin'
22
import type { Options } from './types'
33
import { createUnplugin } from 'unplugin'
44

src/nuxt.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import type { Options } from './types'
22
import { addVitePlugin, addWebpackPlugin, defineNuxtModule } from '@nuxt/kit'
33
import vite from './vite'
44
import webpack from './webpack'
5-
import '@nuxt/schema'
65

76
export interface ModuleOptions extends Options {
87

tsdown.config.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import { defineConfig } from 'tsdown'
2+
3+
export default defineConfig({
4+
entry: ['src/*.ts'],
5+
format: ['esm', 'cjs'],
6+
})

tsup.config.ts

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)