Notice: The Monaca & Onsen UI Community Forum is shutting down.

For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.

Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.

Monaca NPM v3 install



  • Hi,

    I am trying to install onsen ui v2 toolkit. I am using node 7 and npm v3 on mac os x. When trying to install it seems to get stuck on this. Is there anything else I can do to install onsen ui?

    npm install -g monaca

    npm verb get saving npm to /Users/lsh/.npm/registry.npmjs.org/npm/.cache.json
    npm verb correctMkdir /Users/lsh/.npm correctMkdir not in flight; initializing
    npm verb cache add spec npm@^2.10.x
    npm verb addNamed “>=2.10.0 <3.0.0” is a valid semver range for npm
    npm verb addNameRange registry:https://registry.npmjs.org/npm not in flight; fetching
    npm verb get https://registry.npmjs.org/npm not expired, no request
    npm verb addNamed “2.15.11” is a plain semver version for npm
    npm verb addRemoteTarball https://registry.npmjs.org/npm/-/npm-2.15.11.tgz not in flight; adding
    npm verb addRemoteTarball [ ‘https://registry.npmjs.org/npm/-/npm-2.15.11.tgz’,
    npm verb addRemoteTarball ‘350588fba9cd8d384cf9a6e8dc0fef0f94992b7c’ ]
    npm info retry fetch attempt 1 at 12:00:56 AM
    npm info attempt registry request try #1 at 12:00:56 AM
    npm http fetch GET https://registry.npmjs.org/npm/-/npm-2.15.11.tgz
    npm http fetch 200 https://registry.npmjs.org/npm/-/npm-2.15.11.tgz
    ⸨ ░░░░░░░░░░░░░░⸩ ⠋ fetchMetadata: http fetch 200 https://registry.npmjs.org/npm/-/npm-2.15.11.tgz
    ⸨ ░░░░░░░░░░░░░░⸩ ⠧ fetchMetadata: http fetch 200 https://registry.npmjs.org/npm/-/npm-2.15.11.tgz
    ⸨ ░░░░░░░░░░░░░░⸩ ⠹ fetchMetadata: http fetch 200 https://registry.npmjs.org/npm/-/npm-2.15.11.tgz



  • After one hour of waiting there’s more errors, seems to be on cordova hello app…

    npm verb addTmpTarball /tmp/npm-9976-5cb7f4d4/registry.npmjs.org/npm/-/npm-2.15.11.tgz not in flight; adding
    npm verb addTmpTarball already have metadata; skipping unpack for npm@2.15.11
    npm verb correctMkdir /Users/lsh/.npm correctMkdir not in flight; initializing
    npm verb afterAdd /Users/lsh/.npm/npm/2.15.11/package/package.json not in flight; writing
    npm verb correctMkdir /Users/lsh/.npm correctMkdir not in flight; initializing
    npm verb afterAdd /Users/lsh/.npm/npm/2.15.11/package/package.json written
    npm verb correctMkdir /Users/lsh/.npm correctMkdir not in flight; initializing
    npm verb addBundled extract /Users/lsh/.npm/npm/2.15.11/package.tgz
    npm verb tar unpack /Users/lsh/.npm/npm/2.15.11/package.tgz
    npm verb tar unpacking to /tmp/npm-9976-5cb7f4d4/unpack-f18cf281
    npm verb gentlyRm don’t care about contents; nuking /tmp/npm-9976-5cb7f4d4/unpack-f18cf281
    npm verb stack Error: shasum check failed for /tmp/npm-9976-5cb7f4d4/registry.npmjs.org/cordova-app-hello-world/-/cordova-app-hello-world-3.10.0.tgz
    npm verb stack Expected: e3825fc6ca950090a6a37437fcfb88c1622fd80e
    npm verb stack Actual: 7132d7b6d0b93c22d594fb03133f83da1752b1bb
    npm verb stack From: https://registry.npmjs.org/cordova-app-hello-world/-/cordova-app-hello-world-3.10.0.tgz
    npm verb stack at /usr/local/lib/node_modules/npm/node_modules/sha/index.js:25:8
    npm verb stack at ReadStream.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/sha/index.js:72:7)
    npm verb stack at emitNone (events.js:91:20)
    npm verb stack at ReadStream.emit (events.js:185:7)
    npm verb stack at endReadableNT (_stream_readable.js:974:12)
    npm verb stack at _combinedTickCallback (internal/process/next_tick.js:74:11)
    npm verb stack at process._tickCallback (internal/process/next_tick.js:98:9)
    npm verb cwd /Users/lsh/testing_here
    npm ERR! Darwin 13.3.0
    npm ERR! argv “/usr/local/bin/node” “/usr/local/bin/npm” “install” “-g” “monaca” "–verbose"
    npm ERR! node v7.0.0
    npm ERR! npm v3.10.8

    npm ERR! shasum check failed for /tmp/npm-9976-5cb7f4d4/registry.npmjs.org/cordova-app-hello-world/-/cordova-app-hello-world-3.10.0.tgz
    npm ERR! Expected: e3825fc6ca950090a6a37437fcfb88c1622fd80e
    npm ERR! Actual: 7132d7b6d0b93c22d594fb03133f83da1752b1bb
    npm ERR! From: https://registry.npmjs.org/cordova-app-hello-world/-/cordova-app-hello-world-3.10.0.tgz
    npm ERR!
    npm ERR! If you need help, you may report this error at:
    npm ERR! https://github.com/npm/npm/issues
    npm verb exit [ 1, true ]



  • @Leng-Sheng-Hong I can’t tell you how to use NPM as I don’t use it, but to get Onsen up and working FAST, just copy and paste this into the head section of your index.html file.

    <link rel="stylesheet" href="https://unpkg.com/onsenui/css/onsenui.css" type="text/css" media="all" />
     <link rel="stylesheet" href="https://unpkg.com/onsenui/css/onsen-css-components.css">
     <script src="https://unpkg.com/onsenui"></script>