Masthash

#pnpm

Michal Bryxรญ ๐ŸŒฑ
4 days ago

Can someone share some relatively up-to-date *.Dockerfile & #docker compose that is useable for local development & #CI when using #EmberJS & #pnpm (#monorepo)?

robrich
5 days ago
Thomas Frans ๐Ÿ‡บ๐Ÿ‡ฆ
1 week ago

How not to do error messages.

(And no, I didn't forget to screenshot the part where it mentioned the duplicate dependency...)

#TypeScript #JavaScript #pnpm #web #webdev

Bryce Wray
1 week ago

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.)

#WebDev #npm #pnpm

Drew Powers
1 month ago

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.

Steve Frenzel
1 month ago

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...

Successful Astro install using pnpm
Successful Astro install using yarn
Unsusccessful Astro install using npm, throwing a bunch of errors I have no clue how to fix

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.....

#pnpm #npm #javascript

lgersman
2 months ago

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`

#pnpm #monorepo #build #order

lgersman
2 months ago

Lazily migrating from nvm to pnpm is piece of cake.

Example: Use .nvmrc to install the required nodejs version of your project using just pnpm :

pnpm env use --global $(cat .nvmrc)

That's it !

#pnpm #nodejs #npm

lgersman
2 months ago

Did you know that you don't need nvm / volta and friends anymore if you use pnpm as npm package manager replacement ?

pnpm can also install the desired nodejs version without any other tools.

https://pnpm.io/cli/env

#npm #pnpm #volta #npm #nodejs

erdbeere ๐Ÿ“
2 months ago

Today I migrated a very big Angular project from `yarn` (1.x legacy) to `pnpm`. I had some smaller issues and it took me some hours, but the requirements installation is now at least 4 times faster than before (it took several minutes before).

#nodejs #angular #npm #pnpm #yarn #javascript

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

Mike Zornek
2 months ago

๐Ÿค” 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?

https://pnpm.io/

Tykayn
3 months ago

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

jolupa :fedora: :gnome:
3 months ago

Algรบ que entengui de #NodeJS o #pnpm que en sร piga dir com passar al terminal l'opciรณ de contestar "Sรญ" per defecte i que no esperi que jo contesti? Grร cies!

freshgum
4 months ago

#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 :-)

#javascript

Matthew Miller :donor:
4 months ago

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.

Doug Parker ๐Ÿ•ธ๏ธ
4 months ago

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.

@noim I don't know. I mean, there's #yarn and #pnpm as #npm alternatives, so I'd be interested in seeing alternate takes on #npx.

Daniel Zenzes
6 months ago

So, Folien sind fertig. Schnell nochmal prรผfen, ob alles auch zum angekรผndigten Talk passt ๐Ÿ˜… #enterjs #pnpm

Mark Stosberg
6 months ago

@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.

#nodejs

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

#webDev #programming #pnpm

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!!!

#NodeJS #JavaScript #yarn

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

Michal Bryxรญ ๐ŸŒฑ
7 months ago

Looking at #YarnBerry being at v4.x now and realising that I don't have (or explicitly know) any project that migrated up from v1.x.
Do people actually keep using #yarn or did everyone migrated away to #pnpm or such?

#Node #WebDev #Tooling

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.

Axel Rauschmayer
8 months ago

โ€œ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

Ian VS
8 months ago

#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

https://storybook.js.org/blog/storybook-7-0/

Ready for review
8 months ago

๐Ÿ“ข 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/ ๐Ÿ˜‡๐Ÿ˜ˆ

Ratul Maharaj
8 months ago

#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

Kevin Renskers :apple:
9 months ago

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.

Chris Manson
9 months ago

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 ๐ŸŽ‰

#emberjs #embroider #javascript #pnpm

NullVoxPopuli
9 months ago

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!)

Docs: https://github.com/NullVoxPopuli/action-setup-pnpm

#JavaScript #pnpm #ci

Pierre
9 months ago
Daniel Zenzes
10 months ago

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.

#rust #rustlang

wish #pnpm had โ€˜btโ€™ command which would run build and then test scripts...

Doug Parker ๐Ÿ•ธ๏ธ
10 months ago

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!

I've been hearing about PNPM for ages now but never had the opportunity to use it on a project.

Before I do though, I want to know what are the pitfalls or reasons not to use it?

:javascript: #JS #Node #NPM #Yarn #PNPM

Florian Geierstanger
11 months ago

TIL #pnpm command line tab-completion, setup with `pnpm install-completion`
https://pnpm.io/completion

mehulkar
11 months ago
Lucas Homer
11 months ago

Okay the #vue dev tools are very nice and I'm enjoying #nuxt and #pnpm and it's thanks to @elk ๐ŸคŒ

Pierre
11 months ago

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

GENKI
11 months ago

#yarn ใฏ v2 ใŒๅ‡บใฆใใŸใ‚ใŸใ‚Šใ‹ใ‚‰ #npm ใซๆˆปใฃใฆไปฅ้™ไฝฟใฃใฆใชใ„ใชโ€ฆ
ใใ—ใฆใใฎๅ‡บๆˆปใ‚Š็ตŒ้จ“ใ‚‚ใ‚ใ„ใพใฃใฆ #pnpm ใจใ‹ใ‚’่ฉฆใ™่…ฐใŒใ™ใ‚“ใ”ใ„้‡ใใชใฃใกใ‚ƒใฃใฆใ‚‹่‡ชๅˆ† :tony_smiling: ๐Ÿ’ฆ

Ian VS
11 months ago

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

Ian VS
1 year ago

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.

๐Ÿ“ฆ NPM vs PNPM

Just got to know about #pnpm as I am trying to run a project that requires it.

If anyone has migrated to pnpm from npm have you faced any challenges, can one use them side by side, as most of my projects are based on #npm I dont what to jump into pnpm straight away.

Ian VS
1 year ago

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.

NaNdy Stalick
1 year ago

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

#npm #pnpm #Node.js

Ian VS
1 year ago

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.

Ian VS
1 year ago

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.

Screencapture of discord video chat, showing the agenda chart for the storybook monthly meeting and 13 participants.