Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .changeset/dts-relative-paths.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@seamless-auth/react": patch
---

Emit relative import paths in the published type declarations. The build kept the
`@/*` tsconfig path aliases in the generated `.d.ts` files, which no consumer can
resolve, so every downstream project silently saw the SDK's public surface as
`any` (masked by `skipLibCheck`). A `tsc-alias` post-build step now rewrites the
aliases to relative paths, restoring real types for consumers.
189 changes: 186 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"npm": ">=9.0.0 <13.0.0"
},
"scripts": {
"build": "node ./scripts/clean-dist.mjs && rollup -c",
"build": "node ./scripts/clean-dist.mjs && rollup -c && tsc-alias -p tsconfig.build.json",
"test": "jest",
"coverage": "npm test -- --coverage",
"typecheck": "tsc --noEmit -p tsconfig.dev.json",
Expand Down Expand Up @@ -96,6 +96,7 @@
"rollup-plugin-peer-deps-external": "^2.2.4",
"rollup-plugin-postcss": "^4.0.2",
"ts-jest": "^29.4.5",
"tsc-alias": "^1.9.1",
"tslib": "^2.7.0",
"typescript": "^5.9.3",
"typescript-eslint": "^8.46.1"
Expand Down
13 changes: 10 additions & 3 deletions tsconfig.build.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,15 @@
"declaration": true,
"declarationDir": "./dist",
"outDir": "./dist",
"sourceMap": true
"sourceMap": true,
"rootDir": "./src"
},
"include": ["src"],
"exclude": ["tests", "**/*.test.ts", "**/*.spec.ts"]
"include": [
"src"
],
"exclude": [
"tests",
"**/*.test.ts",
"**/*.spec.ts"
]
}
Loading