We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
package.json:
{ "type": "module" "dependencies" : { "spacetime": "7.5.0", "typescript": "5.0.4" } }
tsconfig.json:
{ "extends": "@tsconfig/node20/tsconfig.json", "compilerOptions": { "lib": ["es2023"], "module": "node16", "moduleResolution": "node16" "target": "es2022", "strict": true, "esModuleInterop": true, "skipLibCheck": true, "forceConsistentCasingInFileNames": true, "useUnknownInCatchVariables": false, "noUnusedLocals": true, "resolveJsonModule": true, "outDir": "dist/", "baseUrl": ".", "verbatimModuleSyntax": true }, "exclude": ["node_modules"], }
Importing Spacetime like this:
import type { Spacetime } from 'spacetime' import spacetime from 'spacetime'
produces the following Typescript error:
TS2614: Module '"spacetime"' has no exported member 'Spacetime'. Did you mean to use 'import Spacetime from "spacetime"' instead?
Directly importing from spacetime/types/types like mentioned here does not work as well:
spacetime/types/types
TS2307: Cannot find module 'spacetime/types/types' or its corresponding type declarations.
Is there another way to import the types or is something broken? This syntax has been working when my project was still using CommonJS.
Thank you!
The text was updated successfully, but these errors were encountered:
Can you create a small repo that recreates this issue.
Sorry, something went wrong.
Here you go: https://github.com/antonstefer/spacetime-import-issue
Thank you Anton! Will keep this open until it's released, in the next few days. cheers
released as 7.6.0 cheers!
7.6.0
No branches or pull requests
Setup
package.json:
tsconfig.json:
Problem
Importing Spacetime like this:
produces the following Typescript error:
Directly importing from
spacetime/types/types
like mentioned here does not work as well:Is there another way to import the types or is something broken?
This syntax has been working when my project was still using CommonJS.
Thank you!
The text was updated successfully, but these errors were encountered: