Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(js): update dependencies in package.json #9073

Merged
merged 2 commits into from Feb 24, 2022

Conversation

jasongerbes
Copy link
Contributor

Current Behavior

The @nrwl/js:tsc and @nrwl/js:swc executors update the main and typings properties of the output package.json file, but they don't currently update the dependencies/peerDependencies properties.

This behaviour is inconsistent with @nrwl/node:package, @nrwl/angular:package, and @nrwl/web:rollup executors that do update the dependencies/peerDependencies properties based on the project graph.

Expected Behavior

The @nrwl/js:tsc and @nrwl/js:swc executors should update the dependencies/peerDependencies based on the project graph.

The updateBuildableProjectDepsInPackageJson and buildableProjectDepsInPackageJsonType options used by other executors should also be exposed to allow this behaviour to be configurable.

Related Issue(s)

Fixes #8945

@nx-cloud
Copy link

nx-cloud bot commented Feb 22, 2022

☁️ Nx Cloud Report

CI ran the following commands for commit 450c36b. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 7 targets

Sent with 💌 from NxCloud.

@vercel
Copy link

vercel bot commented Feb 22, 2022

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/nrwl/nx-dev/2CDT368phn2WFgQvLffkm9SyeZmE
✅ Preview: https://nx-dev-git-fork-jasongerbes-js-package-json-deps-nrwl.vercel.app

@jasongerbes
Copy link
Contributor Author

Also removed layoutDir from swc.impl.ts (added in #9072), as this doesn't seem to be used

Copy link
Contributor

@nartc nartc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thank you

@nartc nartc merged commit 4287d59 into nrwl:master Feb 24, 2022
@jasongerbes jasongerbes deleted the js-package-json-deps branch February 24, 2022 22:38
meeroslav pushed a commit to meeroslav/nx that referenced this pull request Mar 4, 2022
Co-authored-by: Jason Gerbes <jason.gerbes@vista.co>
@github-actions
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

buildable @nrwl:js/lib doesn't collect dependencies to package.json
3 participants