Open yangwao opened 2 years ago
noted, time to sharpen my writing skill π
hey @preschian how it's going π
Hi @yangwao, hopefully, I can give you the draft blog post in 2 weeks
Currently, I'm still curious about issues related to pnpm, especially after this issue https://github.com/kodadot/nft-gallery/issues/2830#issuecomment-1096666746. To ensure there is no major issue after migration to pnpm. At least I can list down the issue. so far, it seems like the issue occurs on yarn also
Seems loads of fun π
Thank for letting us know, let's keep this issue posted :)
@preschian any progress on this?:)
@preschian any progress on this?:)
hi so sorry, still no major progress on this ππ»
the downside of using node-linker=hoisted
. we face error several times :(
why so brittle...
ππ
πππ
Browsing issues, whats up with this one?
π
ASSIGNED - @poppyseedDev π LOCKED -> Wednesday, May 17th 2023, 20:22:14 UTC -> 48 hours
Provide comments on writing style of article:
KodaDot, an open-source NFT marketplace flourishing on the Dotsama (Kusama/Polkadot) network, has always been known for its commitment to collaboration, inclusivity, and trust. With a thriving community of creators, developers, and members continuously working together to shape the platform, KodaDot is making significant strides in the blockchain and NFT space. However, behind the platform's innovative features and enticing rewards system, there's a team of dedicated developers constantly making decisions and adjustments to ensure the platform's smooth operation and scalability. One such recent decision was the transition from using yarn
to pnpm
in their development workflow.
To understand why KodaDot made this switch, we first need to understand the underlying problem with yarn
and npm
that pnpm
solves - the doppelganger issue.
In JavaScript projects, especially large, complex ones like monorepos, there's a common issue known as the "doppelganger problem." It arises when multiple copies (or "doppelgangers") of the same package exist in a project, leading to inconsistencies, bugs, and confusion. This problem is particularly prominent in monorepos, where a single repository may contain multiple packages or projects, and it's not uncommon for different projects to depend on different versions of the same package.
Yarn and npm, while excellent package managers, can potentially lead to doppelganger packages in monorepos. This occurrence can cause unexpected and hard-to-debug problems, which can slow down development and lead to unstable builds.
Enter pnpm
, a fast, disk-efficient package manager for JavaScript that solves the doppelganger problem by design. Instead of installing multiple copies of the same package, pnpm
uses a shared store and creates hard links or symlinks from there to the node_modules
directories where the packages are used. This approach ensures that a single package version exists in the store, eliminating the possibility of doppelgangers.
Moreover, pnpm
's approach conserves disk space and speeds up installation, particularly valuable in large projects. It also offers strict package isolation, meaning packages are sandboxed and can access only their dependencies, not arbitrary packages in the project. This isolation enhances the project's security and predictability.
KodaDot's switch to pnpm
was a strategic move towards enhancing their development workflow's efficiency, predictability, and security. Being an open-source project with numerous contributors, KodaDot needed a solution that could handle the complexities of their monorepo and provide a reliable environment for their developers.
By choosing pnpm
, KodaDot not only solved the doppelganger problem but also improved the speed and disk efficiency of their development process. This improvement allows the platform to scale effectively, accommodating more contributors, more features, and ultimately, more community members.
Moreover, pnpm
's strict package isolation aligns with KodaDot's commitment to trust and security. The enhanced predictability of the development environment results in fewer bugs and a more stable platform, benefiting both the developers and the end users.
KodaDot's switch from yarn
to pnpm
underscores their commitment to scalability, efficiency, and sustainability. This strategic decision not only enhances their development workflow, but also invites greater open-source contribution and promotes greener practices. The move illustrates how the selection of development tools can profoundly influence a project's growth, stability, and broader impact.
Where do I publish? Link to draft: https://medium.com/@poppyseedDev/cd3e34e7e6
Where do I publish? Link to the draft: https://medium.com/@poppyseedDev/cd3e34e7e6
I gave you access and instructions π₯° happy to see your article.
article submitted for publication
ASSIGNMENT EXPIRED - @poppyseedDev has been unassigned.
tested in:
NPM_FLAGS = --version
as env. sourceimprovements:
impressive time savings. Curious if you would be keen to write an article on how we've migrated from yarn to pnpm? Some people might find it interesting as we are still early! This morning found friends deciding between npm and yarn π .
We are usually publishing at https://medium.com/kodadot :)
Issue is reserved for @preschian
Originally posted by @yangwao in https://github.com/kodadot/nft-gallery/issues/2643#issuecomment-1078864547
Ref