Jump to main content

Nicolas Hoizey

  • articles
  • billets
  • links
  • notes
  • talks
  • archives
  • about

Note from 12 May 2023

  • Nicolas Hoizey
  • 12 May 2023
  • Node, npm
  • 2 reactions

Why would anyone use the path package from npm instead of Node’s path module?

https://www.npmjs.com/package/path

Just found it in one of my own projects, where I'm the only contributor… 😅

2 reactions

1 like

  1. Tyler Sticka avatar

1 reply

  1. Timo Tijhof avatar Timo Tijhof
    @nhoizey The idea of publishing npm built-ins (mostly) as-is, is fairly common in relation to tools like browserify.Those tools can't easily read the source code otherwise and/or the built-in version might not be standalone (eg rely on Node or V8 internals) in a way that would make it work in a browser environment. It also helps control which version is embedded in the build, which otherwise varies by developer env's Node version.See also https://www.npmjs.com/package/events #nodejs #npm
    nodejs
    npm…
    • 13 May 2023, 14:02
    • Source
  • Older: Note from 6 May 2023
  • Newer: Note from 13 May 2023

Related content with similar topics

  1. Updating npm packages versions in package.json

    • Nicolas Hoizey
    • 6 March 2020
    • Node, npm
    • 5 reactions

    I chose to use npm-check-updates to check for available updates of packages in my package.json files, and it always works without issues, so I guess I can recommend it. I'm also using this as a reminder for my own use… 😁

If you want to share an error or suggest an enhancement of this content, please edit the source on GitHub.

© Nicolas Hoizey

Built with Eleventy