Skip to content

Babel-Jest and Jest Versions Incompatible w/ React-Scripts Dependency-Requirements #78

@ZiaMM

Description

@ZiaMM

Step 1: Are you in the right place?

I think so, as it occurs when following the read-me instructions and is the result of node-package versions which specified in the package.json file, but incompatible.

Step 2: Describe your environment

  • template name :re-start
  • template version : 0.0.1
  • react-native version: 0.59.5
  • OS : Linux
  • Platform causing error: web (didn't try others)

Step 3: Describe the problem (try to include screenshots):

First error - Could not find react-native-windows@0.59.. Latest version of react-native-windows is 0.57.1, try switching to react-native@0.57..
I did not attempt to troubleshoot/fix this, as I am only interested in web, iOS, Android. After commenting out "enableWindows();" in ./finishInstall.js this script ran OK.

Then ...
Errors on attempting to start - first citing incompatible versions of babel-jest / jest, then ELIFECYCLE error crash.

Steps to reproduce:

Following the read-me instructions

Expected Results:

Installs & Starts OK

How I fixed it: (maybe?)

In the package.json,

  • I changed the react-scripts to the latest minor version within the major-version (v2.1.8).
  • I removed from defDependencies "babel-jest" and "jest" ( so react-scripts compatible versions would be installed - v23.6.0 vs the v24.7.1 specified )

Then:

  • deleted the node_modules folder
  • ran yarn

Was able to run "npm run web" and get the default-page to load OK. I am unsure of any new problems this may have created, if functionality in v24 of babel-jest and jest are needed for functionality beyond the demo-page.

Note there is no src/screens/EntryScreen or src/components/TopLevelComponent.js in "re-start" - so the demo screen shows "re-route" instead. It might be a good idea to include those, if only just so they would overwrite the "re-route" ones, so a new-user knows they didn't miss installing the last template (re-start) over the others.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions