question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

react and react-dom dependencies should have caret range

See original GitHub issue

I think https://github.com/facebookincubator/create-react-app/pull/1253 made it so that react and react-dom are also installed with exact range:

  "dependencies": {
    "react": "15.4.2",
    "react-dom": "15.4.2"
  },
  "devDependencies": {
    "react-scripts": "0.9.2"
  },

This is not right. We want to pin react-scripts but leave react and react-dom unpinned:

  "dependencies": {
    "react": "^15.4.2",
    "react-dom": "^15.4.2"
  },
  "devDependencies": {
    "react-scripts": "0.9.2"
  },

The easiest way to do it would probably be to remove the exact flag from the installation script in packages/create-react-app/index.js, and instead pin react-scripts to a specific version in the same function that moves react-scripts to devDependencies (also in that file).

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:9 (9 by maintainers)

github_iconTop GitHub Comments

2reactions
johann-sonntagbauercommented, Feb 27, 2017

THX that will be a perfect spot. Try to formulate a PR.

0reactions
Timercommented, Mar 1, 2017

Fixed in #1669. Thanks @johann-sonntagbauer!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Issues with react and react-dom dependencies - Stack Overflow
I am using VSCode and when i run the script using inbuilt run, i get an error that states that To run ES...
Read more >
npm Peer Dependencies - Fathom
Peer dependencies effectively declare a dependency without including the dependency in your built module. When an application includes your module, that ...
Read more >
ReactDOM – React
The react-dom package provides DOM-specific methods that can be used at the top level of your app and as an escape hatch to...
Read more >
How should you pin dependencies and why? – The Guild
By freezing the dependencies we want to achieve repeatable deployment and make sure that every developer is testing on the very same codebase....
Read more >
Blog - Coorva
I've been working with my team on a software development project, ... Finally, for react-dom , running npm update will update the package ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found