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

Workspaces blog post #580

Merged
merged 5 commits into from
Aug 3, 2017
Merged

Workspaces blog post #580

merged 5 commits into from
Aug 3, 2017

Conversation

bestander
Copy link
Member

@bestander bestander commented Jul 24, 2017

Started a blog post about Yarn Workspaces.

--- update 31.07.2017
For those waiting for this PR to get merged.
The team decided to hold off the blog post for a couple of weeks to allow some time for bug fixing.
Feedback is still welcome.

Started a blog post about Yarn Workspaces
@Haroenv
Copy link
Member

Haroenv commented Jul 24, 2017

Deploy preview ready!

Built with commit 328e501

https://deploy-preview-580--yarnpkg.netlify.com

@Bnaya
Copy link

Bnaya commented Jul 26, 2017

The file extension is not .md so GH won't process the markdown for preview

}`
```

An approach that a wrapper like Lerna takes is to run run `yarn install` for each package.json separately and then run `yarn link` for packages that depend on each other.
Copy link

Choose a reason for hiding this comment

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

'... Lerna takes is to run run ...' ?

@svenefftinge
Copy link

So the behavior is the same as using --hoist in lerna. Maybe you should mention that.

@rarkins
Copy link

rarkins commented Jul 31, 2017

Is the yarn.lock content in the project root expected to be the same regardless of which package.json subdirectory it's run from?


Do Yarn Workspaces make Lerna obsolete?

Not at all.
Copy link
Contributor

Choose a reason for hiding this comment

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

This might be a bit misleading. While the current implementation of Yarn Workspaces might not totally replace the functionality of Lerna, the intention is that it will.

Yarn should solve many of the same problems and people should start adapting their tools to work on top of Yarn Workspaces instead of Lerna. I want to eventually deprecate Lerna altogether.

Copy link
Member Author

Choose a reason for hiding this comment

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

This could be a different discussion for a different time.
By the time Yarn arrives to feature parity with Lerna the latter may have some opinionated and specific features that Yarn team would not want to copy or maintain.

It will be up to Lerna maintainers to make this decision.

Copy link
Contributor

Choose a reason for hiding this comment

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

I designed Lerna so that it intentionally wouldn't have features like that, things that were added should be entirely rethought on top of workspaces

@bestander
Copy link
Member Author

Is the yarn.lock content in the project root expected to be the same regardless of which package.json subdirectory it's run from?

yarn.lock in the root will contain all the resolutions for all workspaces' package.json files.
If you run yarn install in a workspace folder Yarn will automatically cd to the root and run it from there

@bestander bestander changed the title [WIP] Workspaces blog post Workspaces blog post Aug 3, 2017
@bestander bestander merged commit a76aa31 into master Aug 3, 2017
@Haroenv Haroenv deleted the bestander-workspaces-blog branch August 4, 2017 05:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants