🍁 Check specific packages to have a single resolved version in yarn.lock
-
Install
canadyarn
.$ yarn add --dev canadyarn
-
Add the key
"checkSingleVersionDependencies"
topackage.json
file,
specify the names of packages to check as a string array,
and addcanadyarn
as a runnable script.Example:
{ "checkSingleVersionDependencies": [ "react", "react-native", "typescript" ], "scripts": { "canadyarn": "canadyarn" } }
-
Run
canadyarn
.$ yarn run canadyarn