vue-meteor icon indicating copy to clipboard operation
vue-meteor copied to clipboard

Vue-component hot reload not working for css files

Open SnooHD opened this issue 8 years ago • 5 comments

I have an issue with the hot reload when i change any of my scss files. I don't have any problems with other files types.

I'm using vue-component 0.10.3 But i noticed this same error comes up with older versions as well.

Error server side: Exception in callback of async function: TypeError: Cannot read property 'hash' of null at hotCompile (packages/vue-component/plugin/vue-compiler.js:324:15) at runWithEnvironment (packages/meteor.js:1176:24)

Error client side (the file does exist): [vue-component] Error while compiling in tag <style> using lang scss File to import not found or unreadable: C:\Users\Mike\Meteor\logopicker\imports\client\ui\step3\tools\tools.scss. Parent style sheet: stdin

If any other details are needed, let me know. Thanks a bunch!

SnooHD avatar Jul 30 '17 23:07 SnooHD

In your .vue file you set lang="scss" ?

<style lang="scss"></style>

alexandesigner avatar Jul 31 '17 11:07 alexandesigner

This is my style tag:

<style lang="scss">
  @import 'tools';
</style>

Funny thing is that sometimes it does seem to work as it should.. But most of the time it simply does not.

SnooHD avatar Jul 31 '17 11:07 SnooHD

Checks the path of the file you are importing.

I've created a play and it seems to be working fine, take a look and see what may be different:

See https://github.com/alexandesigner/meteor-vue-issue232

For more information visit Package SASS

alexandesigner avatar Jul 31 '17 13:07 alexandesigner

Hmm i guess i should mention that i'm changing the files from a different computer on my local network. When i directly change the files on the computer running meteor, its seems to work fine. When i use my laptop to change the files through the network using file sharing, i get this error..

FYI; I don't have a second screen to attach to my computer so i'm using my laptop for this purpose.

I changed my laptop to be the browser-preview screen, so this indirectly solves the issue for me. Though, it still seems weird to me that it doesn't work..

SnooHD avatar Jul 31 '17 15:07 SnooHD

This may be a nodejs limitation. I didn't try editing the project file over the network yet.

Akryum avatar Aug 11 '17 04:08 Akryum