static-dev / spike

A modern static build tool, powered by webpack
http://spike.js.org
Other
470 stars 29 forks source link

Fresh install: receiving ModuleBuildError #64

Closed timcreatewell closed 7 years ago

timcreatewell commented 7 years ago

Hi there,

I've only recently come across Spike and keen to give it a test drive, but unfortunately am running into issues immediately after a fresh install (npm install spike -g) and creating a new project (spike new test-project).

When I try to run my new project (spike watch) I immediately receive in the terminal the following warning:

⚠ WARNING
{ ModuleBuildError: Module build failed: Error: Options {"modules":false} passed to a preset which does not accept options.
    at /development/test-project/node_modules/babel-core/lib/transformation/file/options/option-manager.js:314:17
    at Array.map (native)
    at OptionManager.resolvePresets (/development/test-project/node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
    at OptionManager.mergePresets (/development/test-project/node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
    at OptionManager.mergeOptions (/development/test-project/node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
    at OptionManager.init (/development/test-project/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
    at File.initOptions (/development/test-project/node_modules/babel-core/lib/transformation/file/index.js:212:65)
    at new File (/development/test-project/node_modules/babel-core/lib/transformation/file/index.js:135:24)
    at Pipeline.transform (/development/test-project/node_modules/babel-core/lib/transformation/pipeline.js:46:16)
    at transpile (/development/test-project/node_modules/babel-loader/lib/index.js:48:20)
    at Object.module.exports (/development/test-project/node_modules/babel-loader/lib/index.js:163:20)
    at runLoaders (/usr/local/lib/node_modules/spike/node_modules/webpack/lib/NormalModule.js:192:19)
    at /usr/local/lib/node_modules/spike/node_modules/loader-runner/lib/LoaderRunner.js:364:11
    at /usr/local/lib/node_modules/spike/node_modules/loader-runner/lib/LoaderRunner.js:230:18
    at runSyncOrAsync (/usr/local/lib/node_modules/spike/node_modules/loader-runner/lib/LoaderRunner.js:143:3)
    at iterateNormalLoaders (/usr/local/lib/node_modules/spike/node_modules/loader-runner/lib/LoaderRunner.js:229:2)
    at Array.<anonymous> (/usr/local/lib/node_modules/spike/node_modules/loader-runner/lib/LoaderRunner.js:202:4)
    at Storage.finished (/usr/local/lib/node_modules/spike/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:38:15)
    at /usr/local/lib/node_modules/spike/node_modules/enhanced-resolve/lib/CachedInputFileSystem.js:69:9
    at /usr/local/lib/node_modules/spike/node_modules/graceful-fs/graceful-fs.js:78:16
    at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:439:3) id: '158eb406' }
compiled (0.723s)

This warning doesn't seem to stop Spike from running, and the website launches in my browser, however I'm unsure whether this warning will cause any further issues down the track? For example, I have since tried to include configuration for sass in my app.js, but it doesn't seem to be working - which could be a configuration problem, or this warning could be the issue?

I am currently running spike v1.3.0 and node v7.9.0.

Any advice or help would be greatly appreciated! Thanks :)

jescalan commented 7 years ago

Hey so this is weird, I am unable to reproduce. Can you send a few more details on your system and what versions you are running of everything?

timcreatewell commented 7 years ago

Hi @jescalan , thanks for getting back in touch. I have just tried updating both node and npm on my machine (node is now v7.10.0 and npm is v4.6.1), created a new fresh project and it now works fine :)

My guess is that it likely may have been my version of npm (it was previously v4.2.0). I don't remember seeing anything in the docs about npm, but sorry if I missed it!

Thanks for taking a look for me.

jescalan commented 7 years ago

Ah glad it worked out! 🙌