Skip to content
New issue

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

Cannot find name 'Map' in @types/k6/experimental/browser.d.ts:1563 (0.48.0) #67957

Open
mohsenny opened this issue Dec 24, 2023 · 1 comment
Open

Comments

@mohsenny
Copy link

I'm getting this error when I'm compiling my test:

node_modules/@types/k6/experimental/browser.d.ts:1563:22 - error TS2583: Cannot find name 'Map'. Do you need to change your target library? Try changing the 'lib' compiler option to 'es2015' or later.

1563     getProperties(): Map<string, JSHandle>;
                          ~~~


Found 1 error in node_modules/@types/k6/experimental/browser.d.ts:1563

This is my tsconfig.json:

{
  "compilerOptions": {
    "target": "esnext",
    "module": "commonjs",
    "lib": ["es2015", "dom", "es2015.collection"],
    "allowJs": true,
    "outDir": "./dist",
    "rootDir": ".",
    "strict": true,
    "esModuleInterop": true,
    "skipLibCheck": true,
    "forceConsistentCasingInFileNames": true
  },
  "include": [
    "scenarios/**/*"
  ],
  "exclude": [
    "node_modules",
    "**/*.test.ts"
  ]
}

Any idea what might be wrong?

@jakebailey
Copy link
Member

If you remove the node_modules exclude, does it work?

This folder is typically not excluded.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants