#pnpm
https://dev.to/hmans/how-i-monorepo-october-2022-edition-1ib4 - Tools for #Monorepos: 1. #pnpm, 2. ... 3. ... 4. #GitHub Actions, 5. ... 6. Nice collection https://www.linkedin.com/in/hmans/.
How not to do error messages.
(And no, I didn't forget to screenshot the part where it mentioned the duplicate dependency...)

Hoping to spare others a headache. If your project...
(a.) uses pnpm
and
(b.) uses `npm-run-all`
and
(c.) has a `package.json` with a `config` object and a `name` item
... youโll have bugs with any scripts using `npm-run-all`. (https://github.com/mysticatea/npm-run-all/issues/249)
Until this bug is fixed:
(1.) Remove the `name` item.
...or...
(2.) Remove the `config` object.
...or...
(3.) Use `concurrently` for parallel stuff **or** the old `&&` thingy for sequential stuff. (My recommendation.)
Why everyone should switch to #pnpm: itโs fast.
โฆthatโs it. Donโt discount the power of a minute (or more) saved everywhereโin every CI, every container, every developer on your team. Seconds matter when the end result is the same.
Posted this on @astro #discord but maybe someone here can help?
I can't install a new #astro project by running "npm create astro@latest". Using #pnpm and #yarn works just fine.
#node version: 20.9.0 & #npm is 10.1.0. Tried installing #svelte with npm for comparison & got a similar error, so it's a local issue? When using "npm install" to install #11ty it works with no issues.
Could anyone point me to a direction how to fix this? I'm not very familiar with debugging these kind of things...
OK #pnpm is pretty cool... Guess there are now 2 good #Typescript programs out there. I love how fast it is, and I love that it FINALLY prevents me from accidentally importing stuff from the wrong package because the language server just happens to see a similar item in an indirect dependency. It's great. Sanity restored.
The most wtf moment happened to me today when I ran `git add package.json pnpm-lock.yaml` and it started installing packages, only to realise I actually typed `pnpm` instead of `git`.
Apparently both `package.json` and `pnpm-lock.yaml` are npm modules.....
TIL : PNPM can be used to compute the build/depedency order of your workspace packages using `pnpm list` (https://pnpm.io/cli/list) ๐ !
Examples:
`pnpm list --parseable --recursive --only-projects`
`pnpm list --json --recursive --only-projects`
I don't know what #pnpm is doing, but on Windows NTFS, this test project takes 30s+ to install from a hot cache, but the same project on ReFS (thus, with clonefile support) takes 3-4s.
At the same time, I'm not seeing any DeviceIoControl calls in the flamegraph for pnpm, which makes me wonder if they're doing something completely different.
/cc @zkochan
๐ค I'm considering using #pnpm over #npm for my #SvelteKit project.
I'm mostly interested in a more human-readable lock file for git diffs.
What else should I consider?
y'a trop de gestionnaires de paquet, je vais en faire un pour tous les maรฎtriser.
ainsi naquit #Ni pour gรฉrer #yarn, #pnpm, #npm, et #bun.
#xkcd serait fier de รงa.
#shrawberry #nightswhosayni

#PNPM comes with nvm built in, btw. https://pnpm.io/cli/env
It's such a well-kept secret, for some reason. Like, this is really cool :-)
SimpleWebAuthn v8.0.0 has been released! The highlight of this release: first-class Deno support, as well as unofficial support for CloudFlare Workers and Bun! Basically anything that can run JavaScript or TypeScript on the back end should now be able to pull in this project, including CommonJS and ECMAScript modules!
Check out the changelog, there are a couple of minor breaking changes:
https://github.com/MasterKale/SimpleWebAuthn/releases/tag/v8.0.0
And if you have a Deno project you've been wanting to use SimpleWebAuthn with (without having to resort to npm:
specifiers) you can find the project on deno.land here:
https://deno.land/x/simplewebauthn@v8.0.0
Time to rest ๐ฎโ๐จ
#simplewebauthn #node #nodejs #deno #bun #cloudflare #typescript #javascript #webauthn #passkeys #pnpm #lerna
I opened an "old" project that was using #YarnPkg (classic) as package manager, with the aim of updating a couple of dependencies.
It turns out that Yarn "decided" to jump straight ahead to its newest version (Berry 3.6.1) without asking.
It broke my flow: it's unable to interpret a POSIX shell `if` inside a command of the `scripts` section.
It was easy to fix, but certainly quite annoying.
I was considering switching to #PNPM, now I'll do that for sure.
Just lost a whole night of productivity trying to bump *one* dependency exactly *one* version.
2 hours later I've done at least 3 bisecting operations on 3 different repos, can't get #pnpm to install the same thing twice, and still haven't got the lockfile updated to the latest version.
This isn't entirely the fault of #NPM / pnpm. But I manage dependencies very precisely and deliberately with a reproducible build system using pinned dependencies.
If I'm having this much trouble with it, I don't know how typical web devs can manage at all. I didn't make any meaningful progress on the problem I was *actually* trying to solve. All I have to show for my efforts is a red CI.
@miladiir I just tested #pnpm to see if it would make my `node_modules` smaller.
Before, with Yarn, the size was 958M.
After, pnpm, the size was 923M.
The number of installed versions of Bluebird dropped from 8 to 3, so it did flatten that dep. ๐
The 3% savings isn't necessarily compelling enough on its own to switch, though.
It's 35k lines long!!! We *just* started moving old packages into the monorepo a few months ago, it's going to get MUCH BIGGER.
#monorepo is an #AntiPattern
Somehow, every #packageManager that tries to replace #NPM is worse than the last.
I can't even open #PNPM's package_lock.json in my company's #monorepo because #VSCode runs out of memory trying to display a changeset.
I don't even WANT a fucking package_lock!!!
I'm thinking about how I could design a good #cli for #hsml
I may orientate on existing CLIs like #Rust, #deno or #pnpm
so e.g.
```bash
hsml compile # compiles all .hsml files to .html inside current folder and recursive below
hsml compile ./example.hsml # just compiles the given file
hsml fmt # formats
hsml fmt # just formats given file
hsml parse ./example.hsml # parses the given file and std::out as json AST
```
But I'm not sure if this fulfills all need or if I need to change something
People who are working with #npm #monorepo's, if I have a package (eslint config) in the monorepo that is used as `devDependency` in other package from the same repo, and that other package is going to be published. Does this `devDependency` has to be published too? Or can it stay private? I really don't see sense publishing it, but also couldn't find information whether npm cares about devDeps...
Also tagging #nx #lerna #turborepo #pnpm #javascript, in case you guys maybe know the answer.
โFlat node_modules is not the only wayโ by @zkochan
[How pnpm manages node_modules]
https://pnpm.io/blog/2020/05/27/flat-node-modules-is-not-the-only-way
#NodeJS #npm #pnpm
#Storybook 7.0 has been officially released, with an obligitory hype video: https://youtu.be/UF3d34a6kqg
Read the announcement for the deets on all the goodies like:
- First-class @vite support
- Zero-config Sveltekit
- Zero-config Next.js
- Improved #TypeScript type safety
- Full #pnpm support
๐ข Da hat sich einiges an Themen angesammelt, die wir besprechen mรผssen. Mit dabei unser geliebtes MS Teams, #zsh, #pnpm, #java 20, #chezmoi, #fdroid und #inkbook. ๐คฏ
๐ ๏ธ Thematisch machen wir einen deep dive zum Thema #javascript build tools.
๐ฆธโโ๏ธIm Konsum besprechen wir dann mal noch fix die ersten drei Phasen des MCU (und das ist der kurze Teil der Folge).
๐ Ach, und wir haben einen Rabattcode fรผr die #enterJS (auch in den Shownotes)
https://ready-for-review.dev/2023/04/12/rfr045-engelsklang-und-teufelszeug/ ๐๐
Misskey 13.11.1 is now available with lots of bug fixes @syuilo
https://github.com/misskey-dev/misskey/releases/tag/13.11.1
#misskey #opensource #foss #fediverse #misskeydev #social #network #socialnetwork #microblog #activitypub #typescript #vue #pnpm #vite
#TIL that you can run `npm version patch` to do a patch (or minor, major etc) version increment which will update your package.json file and create a new git tag. Very cool.
#javascript #typescript #opensource #foss #fosstodon #npm #git #github #pnpm
So far I've used good ol' #NPM for all my JS/TS projects. Lately I've been eying #PNPM, mostly because installs are much faster, although the disk space savings are nice too.
However, I am not 100% convinced that it's the best decision as it's yet another thing that the whole team has to install. One more barrier before you can get the code up and running as a new dev on the team.
Is it worth it? I'm 50/50, can't really decide.
Pro tip time ๐งโ๐ปโฑ
Now that we have automatic unstable releases for embroider packages you can update all of your dependencies in a pnpm monorepo with the following command:
```
pnpm -r update @embroider/test-setup@unstable @embroider/addon-shim@unstable @embroider/addon-dev@unstable @embroider/webpack@unstable
```
This can be super useful to test the upcoming release on a branch in your CI or staging environments ๐
99 problems and a #JavaScript package manager ain't one! #npm #yarn #pnpm
Quick one about enabling #pnpm build on #CloudflarePages ...
Do you use pnpm in your projects?
I just made my first GitHub action that combines 3 common steps into one line, saving you over 10 lines per workflow file!
(in some cases, you could convert 50+ lines to 5!)
Another release for Misskey - upgrade to v13.9.1 now ... server performance improvement and bug fixes
https://github.com/misskey-dev/misskey/releases/tag/13.9.1
#misskey #opensource #foss #fediverse #misskeydev #social #network #socialnetwork #microblog #activitypub #typescript #vue #pnpm #vite

Am 22.06. darf ich auf der #enterjs in Darmstadt erzรคhlen, wie wir unser Projekt auf #pnpm umgestellt haben. Wird ein Praxisbericht mit einigen Dingen, die wir gelernt haben. https://enterjs.de/veranstaltung-20055-0-heute-hoist-ich-morgen-bau-ich--dependency-management-aber-richtig-mit-pnpm.html
So I finally figured out how to deal with some mystery slowness during file extraction in #orogene, and managed to get full extraction working and it is:
๐๐ป 4x faster than #pnpm
๐๐ป 4x faster than #yarn
๐๐ป 3x faster than #npm
...and these are just some initial numbers! There's still some stuff I'm sure I haven't tried to do yet that could bump that further.
On my machine, this means it can fully resolve and install a react app in 11 seconds.
v v exciting results so far.
wish #pnpm had โbtโ command which would run build and then test scripts...
Why is it so unreasonably hard to get #PNPM to generate a damn lockfile? Even if I don't have any dependencies, I still want a lockfile!
TIL #pnpm command line tab-completion, setup with `pnpm install-completion`
https://pnpm.io/completion
[New Post] โ๐ผ Failing to debug pnpm workspaces
https://www.mehulkar.com/blog/2023/01/failing-to-debug-pnpm-workspaces/
#javascript #debugging #frontend #pnpm
New Misskey v13 with rewriten backend released but avoid it. Build issues with new installations and possibly other issues with upgrades as well
If you still want to proceed here's the link to v13: https://github.com/misskey-dev/misskey/releases/tag/13.0.0
#misskey #opensource #foss #fediverse #misskeydev #social #network #socialnetwork #microblog #activitypub #typescript #vue #pnpm #vite
The year 2022 for pnpm
https://pnpm.io/blog/2022/12/30/yearly-update
#EsNextNews #EcmaScript #JavaScript #pnpm
The latest #storybook 7.0 beta has a handful of small #pnpm fixes that I worked on over the last few days. Thank you to those who reported problems.
`pnpx sb@next init` to try it out.
https://github.com/storybookjs/storybook/releases/tag/v7.0.0-beta.19
If you had trouble with #pnpm and #storybook in the past, give the new 7.0 beta a try! It wasn't easy, but we worked hard to make sure pnpm is fully supported without hoisting or workarounds.
Use `pnpx sb@next init` to add Storybook to a project, or `pnpx sb@next upgrade --prerelease` to upgrade an existing Storybook project.
Let me know if you experience any issues.
The #Storybook 7.0 beta has been announced: https://storybook.js.org/blog/7-0-beta/
I and the rest of the team have been working hard to ensure that it works seamlessly with #PNPM, #ViteJS, #Svelte, and more. There's a ton to love in this release.
The holidays are a good time to experiment with new things, so give it a whirl today. And feel free to let me know if you have any trouble, I'm happy to help out.
I want to contribute a new #eInk display to https://github.com/samsonmking/epaper.js #NodeJS but the #pnpm workspaces flow has me baffled.
#MonoRepo blues!
It would be great to get this feature in pnpm too, so I created an issue here: https://github.com/pnpm/pnpm/issues/5695
My PR to tackle the final challenges when using #pnpm and #vitejs in #storybook is green in CI and has at least one approval. :its-happening:
It's https://github.com/storybookjs/storybook/pull/19689 if anyone wants to follow along and try it out once it's released in the next 7.0 alpha.
Great to see so many friendly faces on the #storybook monthly roadmap meeting! We're covering topics like prebundling, first-class #nextjs support, and first-class #pnpm support. These happen every month on the first Monday in our discord: discord.gg/storybook.