Earlier this year, I wrote a post about Why Developers Are Moving To Yarn. This struck a chord with many people who were frustrated with
Some of the key new features of npm@5 are:
- a real lockfile (
- SHA512 hashes
- cache infrastructure completely rewritten
- dowload handling improved with concurrent downloads and better memory management (less OOMs, people!)
npm these changes (and more) have shown speed improvements of 20%-100%. You can read more about what’s new in
npms release post.
Buried in the
npm news is the latest major release of NodeJS (V8). Here are some of the highlights:
- npm@5 is bundled (seriously, npm@5 is an awesome update)
- new (experimental) native code API
More on the release on NodeJS’s official blog.
So, how do you get started using the latest and greatest on CircleCI? Thankfully, it’s very simple to do.
Using NodeJS v8 and npm v5 on CircleCI
Getting started with the new versions of NodeJS and npm is straightforward. npm@5 is bundled with NodeJS 8, so installing the new version of NodeJS is all that is needed.
On CircleCI 1.0:
machine: node: version: 8.0.0 dependencies: pre: - node --version - npm --version
On CircleCI 2.0:
version: 2 jobs: build: docker: - image: node:8.0 steps: - run: name: "Checking Versions" command: | node --version npm --version
Caching / Pre-installing
With CircleCI 1.0, we have pre-built images that builds run on. While NodeJS 8.0.0 isn’t preinstalled on our Ubuntu 14.04 image yet, it should be soon.
Feel free to share your projects and feedback in CircleCI Discuss. We look forward to seeing what you build.