mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: In https://github.com/facebook/react-native/pull/37510, a check was introduced to check if user is using `latest` version of `npx`, but right now it checks for every command executed, but it should only ensure that `latest` is included when creating a new project. In this Pull Request I've added a condition to only warn if `init` was fired. ## Changelog: [GENERAL] [FIXED] - Warn only in `init` command when CLI uses cached `npx` version Pull Request resolved: https://github.com/facebook/react-native/pull/44644 Test Plan: Warning about using `latest` version CLI should only be presented when running `init` command. Reviewed By: arushikesarwani94 Differential Revision: D57681864 Pulled By: blakef fbshipit-source-id: 5c81b9a08141396efcd24539b2560cea16028dd9