From 93c86e39209d842941fd69b8ce30ba74d92b82d4 Mon Sep 17 00:00:00 2001 From: Lewis Cowper Date: Sat, 2 Dec 2017 11:43:42 +0100 Subject: [PATCH] docs: Add running specific node version to examples (#129) --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 436bdd0..130f1bc 100644 --- a/README.md +++ b/README.md @@ -98,6 +98,12 @@ $ npx --node-arg=--inspect cowsay Debugger listening on ws://127.0.0.1:9229/.... ``` +### Specify a node version to run npm scripts (or anything else!) + +``` +npx -p node@8 npm run build +``` + ## SHELL AUTO FALLBACK You can configure `npx` to run as your default fallback command when you type something in the command line with an `@` but the command is not found. This includes installing packages that were not found in the local prefix either.