Unverified Commit d31bb199 authored by Loren ☺️'s avatar Loren ☺️ Committed by GitHub

Fix type-check in Temporal example (#28546)

Before this PR, `cd examples/with-temporal && npm run type-check` fails.

## Documentation / Examples

- [x] Make sure the linting passes
parent 88f27ef9
...@@ -6,7 +6,7 @@ export type Data = { ...@@ -6,7 +6,7 @@ export type Data = {
result: string result: string
} }
function getUserId(token: string): string { function getUserId(token?: string): string {
// TODO if the token is a JWT, decode & verify it. If it's a session ID, // TODO if the token is a JWT, decode & verify it. If it's a session ID,
// look up the user's ID in the session store. // look up the user's ID in the session store.
return 'user-id-123' return 'user-id-123'
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"lib": ["dom", "dom.iterable", "esnext"], "lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true, "allowJs": true,
"skipLibCheck": true, "skipLibCheck": true,
"strict": false, "strict": true,
"forceConsistentCasingInFileNames": true, "forceConsistentCasingInFileNames": true,
"noEmit": true, "noEmit": true,
"esModuleInterop": true, "esModuleInterop": true,
...@@ -12,7 +12,11 @@ ...@@ -12,7 +12,11 @@
"moduleResolution": "node", "moduleResolution": "node",
"resolveJsonModule": true, "resolveJsonModule": true,
"isolatedModules": true, "isolatedModules": true,
"jsx": "preserve" "jsx": "preserve",
"paths": {
"@activities": ["./temporal/src/activities"],
"@activities/*": ["./temporal/src/activities/*"]
}
}, },
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"], "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"] "exclude": ["node_modules"]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment