On my Mac Sierra iβve Nodejs 7.4.0 and iβve tried to install Ionic so:
sudo npm install -g cordova ionic
npm WARN deprecated node-uuid@1.4.7: use uuid module instead
npm WARN deprecated minimatch@0.2.14: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated minimatch@0.3.0: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated node-uuid@1.3.3: use uuid module instead
/usr/local/lib
βββ¬ cordova@6.4.0
βββ¬ cordova-common@1.5.1
β βββ osenv@0.1.4
βββ¬ cordova-lib@6.4.0
β βββ¬ cordova-js@4.2.0
β β βββ¬ browserify@13.1.0
β β βββ¬ browser-resolve@1.11.2
β β β βββ resolve@1.1.7
β β βββ¬ crypto-browserify@3.11.0
β β β βββ¬ browserify-sign@4.0.0
β β β βββ¬ parse-asn1@5.0.0
β β β βββ asn1.js@4.9.1
β β βββ JSONStream@1.3.0
β β βββ resolve@1.2.0
β β βββ¬ stream-http@2.6.0
β β βββ builtin-status-codes@3.0.0
β βββ cordova-serve@1.0.1
β βββ¬ init-package-json@1.9.4
β βββ¬ read@1.0.7
β βββ mute-stream@0.0.7
βββ¬ insight@0.8.4
βββ¬ configstore@1.4.0
β βββ write-file-atomic@1.3.0
βββ¬ request@2.79.0
βββ¬ har-validator@2.0.6
β βββ¬ is-my-json-valid@2.15.0
β βββ jsonpointer@4.0.1
βββ¬ http-signature@1.1.1
βββ¬ sshpk@1.10.1
βββ tweetnacl@0.14.5
npm WARN In ionic@2.1.18 replacing bundled version of cross-spawn with cross-spawn@4.0.2
npm WARN In ionic@2.1.18 replacing bundled version of semver with semver@4.2.0
npm WARN In ionic@2.1.18 replacing bundled version of mime-types with mime-types@2.0.14
npm WARN In ionic@2.1.18 replacing bundled version of form-data with form-data@0.2.0
npm WARN In ionic@2.1.18 replacing bundled version of request with request@2.51.0
npm WARN In ionic@2.1.18 replacing bundled version of ionic-app-lib with ionic-app-lib@2.1.9
npm ERR! Darwin 16.3.0
npm ERR! argv β/usr/local/bin/nodeβ β/usr/local/bin/npmβ βinstallβ β-gβ βcordovaβ "ionic"
npm ERR! node v7.4.0
npm ERR! npm v4.0.5
npm ERR! path /usr/local/lib/node_modules/.staging/ansi-392b32ed
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename β/usr/local/lib/node_modules/.staging/ansi-392b32edβ -> '/usr/local/lib/node_modules/ionic/node_modules/cordova-lib/node_modules/ansiβ
npm ERR! enoent ENOENT: no such file or directory, rename β/usr/local/lib/node_modules/.staging/ansi-392b32edβ -> '/usr/local/lib/node_modules/ionic/node_modules/cordova-lib/node_modules/ansiβ
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /Users/mauro/Documents/Ionic Apps/npm-debug.log
Some help? thanks