Skip to content

Commit

Permalink
generate types in gh actions and vite and tsconfig in examples to che…
Browse files Browse the repository at this point in the history
…ck the type declarations files
  • Loading branch information
interim17 committed Jan 30, 2025
1 parent 116050a commit cbe51e1
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ jobs:
with:
node-version: ${{env.NODE_VERSION}}
- run: npm ci
- run: cd examples && npm ci
- run: npm run generateTypes
- run: npm run typeCheck --if-present

publish-dev:
Expand Down
7 changes: 6 additions & 1 deletion examples/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
"compilerOptions": {
"jsx": "preserve",
"esModuleInterop": true,
"downlevelIteration": true
"downlevelIteration": true,
"baseUrl": ".",
"paths": {
"@aics/simularium-viewer": ["../type-declarations"],
"@aics/simularium-viewer/*": ["../type-declarations/*"]
}
}
}
6 changes: 6 additions & 0 deletions examples/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ export default {
process.env.npm_config_localserver || false
),
},
resolve: {
dedupe: ["react", "react-dom"],
},
optimizeDeps: {
include: ["@aics/simularium-viewer"],
},
server: {
open: "examples/src/index.html",
port: 8080,
Expand Down
4 changes: 2 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "./tsconfig.base",
"include": ["src/**/*", "examples/src/**/*", "vitest.config.ts"],
"exclude": ["src/visGeometry/workers/**/*"],
"include": ["src/**/*", "vitest.config.ts"],
"exclude": ["src/visGeometry/workers/**/*", "examples/src/**/*"],
"compilerOptions": {"types": ["vitest/globals"]}
}

0 comments on commit cbe51e1

Please sign in to comment.