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

Wrong types path #7389

Closed
PieterjanDeClippel opened this issue Nov 28, 2023 · 3 comments
Closed

Wrong types path #7389

PieterjanDeClippel opened this issue Nov 28, 2023 · 3 comments

Comments

@PieterjanDeClippel
Copy link

PieterjanDeClippel commented Nov 28, 2023

Describe the bug

image

Expected behavior

Typescript intellisense

image

Reproduction code

Shipped package.json

{
  "name": "rxjs",
  "version": "7.8.1",
  "description": "Reactive Extensions for modern JavaScript",
  "main": "./dist/cjs/index.js",
  "module": "./dist/esm5/index.js",
  "es2015": "./dist/esm/index.js",
  "types": "index.d.ts",
  "typesVersions": {
    ">=4.2": {
      "*": [
        "dist/types/*"
      ]
    }
  },
  "sideEffects": false,
  ...
}

Reproduction URL

No response

Version

7.8.1

Environment

PS C:\Users\Pieterjan De Clippel> node -v
v18.17.1
PS C:\Users\Pieterjan De Clippel> npm -v
9.6.7

Additional context

For some reason the "types" field in the package.json is wrong

@kwonoj
Copy link
Member

kwonoj commented Nov 28, 2023

#6293

@kwonoj kwonoj closed this as completed Nov 28, 2023
@PieterjanDeClippel
Copy link
Author

@kwonoj Thanks, yes it seems to be Visual Studio related.

Could not find a declaration file for module 'rxjs'

Even VS Code manages to correctly determine the return type of httpClient.post<xxxx>().
It's been working fine for the past 3 years, and now all of a sudden it seems to break down.
Angular CLI doesn't complain about it either.

@PieterjanDeClippel
Copy link
Author

For some reason a new checkout of the repository with the same code doesn't show this problem. Probably something was off with the .angular folder or so

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

Successfully merging a pull request may close this issue.

2 participants