babel-preset-power-assert
babel-preset-power-assert copied to clipboard
Cannot find module 'power-assert'
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
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.
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]