Skip to content

Adds a version check when using --use-pnp#5269

Merged
gaearon merged 1 commit intofacebook:masterfrom
arcanis:pnp-version-check
Oct 3, 2018
Merged

Adds a version check when using --use-pnp#5269
gaearon merged 1 commit intofacebook:masterfrom
arcanis:pnp-version-check

Conversation

@arcanis
Copy link
Copy Markdown
Contributor

@arcanis arcanis commented Oct 3, 2018

This PR ensures that users of --use-pnp are using at least the 1.12 release, which is the first one supported by create-react-app.

Ref #5255

@jimthedev
Copy link
Copy Markdown

This won't work when they are using a nightly version of yarn since semver will throw.

https://repl.it/@jimthedev/IgnorantOutgoingActivemovie

You can handle this in the catch by parsing it a second time after popping off everything after the '.' in the nightly yarn version.

@jimthedev
Copy link
Copy Markdown

Looks like semver.gte('1.13.0-20181006.0202', '1.12.0', { loose:true }) might do it.

@lock lock Bot locked and limited conversation to collaborators Jan 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants