Skip to content
This repository has been archived by the owner on Jan 18, 2022. It is now read-only.

Cannot require('rollup-plugin-vue') #83

Closed
mysticatea opened this issue Apr 1, 2017 · 2 comments
Closed

Cannot require('rollup-plugin-vue') #83

mysticatea opened this issue Apr 1, 2017 · 2 comments

Comments

@mysticatea
Copy link
Member

node-sass, less and stylus are optional dependencies. If you are using scss/sass/less/stylus you should require (yarn add --dev node-sass less stylus) them.
http://vuejs.github.io/rollup-plugin-vue/#/en/2.3/?id=style-languages

The document says so, but I encountered Error: Cannot find module 'node-sass' error even if I don't use sass.

Expected behavior

No errors.

Actual behavior

Error: Cannot find module 'node-sass'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (****\test-
workspace\node_modules\rollup-plugin-vue\dist\rollup-plugin-vue.common.js:24:28)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3)

Steps to reproduce the behavior

  1. $ npm install rollup-plugin-vue
  2. $ node -e "require('rollup-plugin-vue')"
@zhongqf
Copy link

zhongqf commented Apr 7, 2017

not work even after runing yarn add --dev node-sass

@znck
Copy link
Member

znck commented Apr 7, 2017

Hopefully fixed in #85. Would confirm after merging it!

@znck znck closed this as completed in #85 May 3, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants