Skip to content

Commit

Permalink
add example
Browse files Browse the repository at this point in the history
  • Loading branch information
tido64 committed Feb 24, 2025
1 parent f0e25f6 commit 1d586bf
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 1 deletion.
1 change: 1 addition & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,6 @@ packageExtensions:
plugins:
- path: .yarn/plugins/@yarnpkg/plugin-compat.cjs
spec: "@yarnpkg/plugin-compat"
- path: incubator/yarn-plugin-align-deps/index.js
tsEnableAutoTypes: false
yarnPath: .yarn/releases/yarn-4.6.0.cjs
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -228,5 +228,8 @@
}
}
},
"prettier": "./.github/prettierrc.json"
"prettier": "./.github/prettierrc.json",
"rnx-kit": {
"profiles": "./yarn-align-deps.config.js"
}
}
1 change: 1 addition & 0 deletions packages/test-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
"typescript": "^5.0.0"
},
"rnx-kit": {
"profile": "test",
"kitType": "app",
"build": {
"distribution": [
Expand Down
15 changes: 15 additions & 0 deletions yarn-align-deps.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
const profiles = {
"test": {
"dependencies": {
"yoctocolors": "^2.1.1"
}
}
};

module.exports = ({ "rnx-kit": rnxconfig }) => {
if (!rnxconfig || !("profile" in rnxconfig)) {
return;
}

return profiles[rnxconfig.profile];
};
7 changes: 7 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -15834,6 +15834,13 @@ __metadata:
languageName: node
linkType: hard

"yoctocolors@npm:^2.1.1":
version: 2.1.1
resolution: "yoctocolors@npm:2.1.1"
checksum: 10c0/85903f7fa96f1c70badee94789fade709f9d83dab2ec92753d612d84fcea6d34c772337a9f8914c6bed2f5fc03a428ac5d893e76fab636da5f1236ab725486d0
languageName: node
linkType: hard

"yoga-layout-prebuilt@npm:^1.9.6":
version: 1.10.0
resolution: "yoga-layout-prebuilt@npm:1.10.0"
Expand Down

0 comments on commit 1d586bf

Please sign in to comment.