Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot find module 'power-assert' #3

Open
mysticatea opened this issue May 12, 2016 · 2 comments
Open

Cannot find module 'power-assert' #3

mysticatea opened this issue May 12, 2016 · 2 comments

Comments

@mysticatea
Copy link

README.md does not say requires installing power-assert, but I encountered the error: Cannot find module 'power-assert'.
Do I need to install power-assert also?

# I have installed `babel-cli` to global before in order to try small things.
> npm i -g node-cli

# Now I have installed `babel-preset-power-assert` to use it in the test of this module.
> npm i -D babel-register babel-preset-power-assert

# I tried a small experiment with `babel-node` in global.
> babel-node --presets power-assert try.js
module.js:440
    throw err;
    ^

Error: Cannot find module 'power-assert'
    at Function.Module._resolveFilename (module.js:438:15)
    at Function.Module._load (module.js:386:25)
    at Module.require (module.js:466:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (try.js:12:16)
    at Module._compile (module.js:541:32)
    at loader (C:\Users\t-nagashima.AD\nodist\bin\node_modules\babel-cli\node_modules\babel-register\lib\node.js:158:5)
    at Object.require.extensions.(anonymous function) [as .js] (C:\Users\t-nagashima.AD\nodist\bin\node_modules\babel-cli\node_modules\babel-register\lib\node.js:168:7)
    at Module.load (module.js:456:32)
    at tryModuleLoad (module.js:415:12)

  • Node 6.1.0
  • npm 3.7.5
@twada
Copy link
Member

twada commented May 12, 2016

Ah, so sorry. That's a problem.
I'll add power-assert as peerDependencies to here and babel-plugin-empower-assert.

And update README too.

Thanks.

@mysticatea
Copy link
Author

mysticatea commented May 12, 2016

I got it. Thank you.

FYI: I have not seen PEER_INVALID warning here. :D

> npm i -D babel-register babel-preset-power-assert

+-- [email protected]
| +-- [email protected]
| `-- [email protected]
|   +-- [email protected]
|   +-- [email protected]
|   | +-- [email protected]
|   | | +-- [email protected]
|   | | `-- [email protected]
|   | +-- [email protected]
|   | | `-- [email protected]
|   | +-- [email protected]
|   | +-- [email protected]
|   | +-- [email protected]
|   | `-- [email protected]
|   +-- [email protected]
|   +-- [email protected]
|   | +-- [email protected]
|   | +-- [email protected]
|   | +-- [email protected]
|   | +-- [email protected]
|   | `-- [email protected]
|   `-- [email protected]
|     +-- [email protected]
|     `-- [email protected]
+-- [email protected]
| +-- [email protected]
| | +-- [email protected]
| | | `-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | | `-- [email protected]
| | +-- [email protected]
| | | +-- [email protected]
| | | +-- [email protected]
| | | | `-- [email protected]
| | | `-- [email protected]
| | +-- [email protected]
| | | +-- [email protected]
| | | `-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | +-- [email protected]
| | `-- [email protected]
| +-- [email protected]
| | +-- [email protected]
| | `-- [email protected]
| +-- [email protected]
| +-- [email protected]
| `-- [email protected]
|   `-- [email protected]
`-- [email protected]
  +-- [email protected]
  | `-- [email protected]
  `-- [email protected]
    `-- [email protected]
      `-- [email protected]

twada added a commit that referenced this issue May 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants