yarn.lock ignoring the ^ (caret) symbol?

14 views Asked by At

So I was reading the the yarn.lock and found this

"@types/react@*", "@types/react@^16.13.1 || ^17.0.0", "@types/react@^16.13.1 || ^17.0.0 || ^18.0.0", "@types/react@^16.9", "@types/react@^18", "@types/react@^18.0.5":
  version "18.2.66"
  resolved "https://our-private-artifactory/react-18.2.66.tgz#d2eafc8c4e70939c5432221adb23d32d76bfe451"
  integrity sha512-OYTmMI4UigXeFMF/j4uv0lBBEbongSgptPrHBxqME44h9+yNov+oL6Z3ocJKo0WyXR84sQUNeyIp9MRfckvZpg==
  dependencies:
    "@types/prop-types" "*"
    "@types/scheduler" "*"
    csstype "^3.0.2"

In other words "@types/react@^16.13.1 || ^17.0.0" was resolved by "18.2.66". That shouldn't have happened. Can you explain why this happened? Is yarn not respecting the caret symbol?

0

There are 0 answers