Skip to content

Commit

Permalink
Generate type declarations for parser package
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisllontop committed Sep 4, 2024
1 parent 54ac603 commit 62a56ba
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions packages/parser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
}
},
"scripts": {
"build:types": "tsc --project tsconfig.types.json",
"build": "rspack build",
"lint": "biome format",
"lint:fix": "biome format --write"
Expand Down
4 changes: 2 additions & 2 deletions packages/parser/rspack.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { fileURLToPath } from 'url';
import { dirname, resolve } from 'path';
import { fileURLToPath } from "url";
import { dirname, resolve } from "path";
import { defineConfig } from "@rspack/cli";

const __filename = fileURLToPath(import.meta.url);
Expand Down
1 change: 1 addition & 0 deletions packages/parser/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"isolatedModules": true,
"jsx": "preserve",
"allowSyntheticDefaultImports": true,
"declaration": true,
"sourceMap": true,
"outDir": "./dist",
"baseUrl": "./",
Expand Down
6 changes: 6 additions & 0 deletions packages/parser/tsconfig.types.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"emitDeclarationOnly": true
}
}

0 comments on commit 62a56ba

Please sign in to comment.