Kaynağa Gözat

chore(oxlint-config): migrate build to tsdown

xingyu4j 3 ay önce
ebeveyn
işleme
c1b1fe90fd

+ 0 - 7
internal/lint-configs/oxlint-config/build.config.ts

@@ -1,7 +0,0 @@
-import { defineBuildConfig } from 'unbuild';
-
-export default defineBuildConfig({
-  clean: true,
-  declaration: true,
-  entries: ['src/index'],
-});

+ 2 - 1
internal/lint-configs/oxlint-config/package.json

@@ -12,7 +12,8 @@
   "license": "MIT",
   "type": "module",
   "scripts": {
-    "stub": "pnpm unbuild --stub"
+    "build": "pnpm exec tsdown",
+    "stub": "pnpm exec tsdown"
   },
   "files": [
     "dist"

+ 11 - 0
internal/lint-configs/oxlint-config/tsdown.config.ts

@@ -0,0 +1,11 @@
+import { defineConfig } from 'tsdown';
+
+export default defineConfig({
+  clean: true,
+  dts: true,
+  entry: ['src/index.ts'],
+  format: ['esm'],
+  outExtensions: () => ({
+    dts: '.d.ts',
+  }),
+});