vue-meteor
vue-meteor copied to clipboard
Dependency manager doesn't watch dependences after Meteor is restarted
If your .vue file pulls in other scss files, changing those files won't trigger a change in your file unless your file has been changed since you started running Meteor.
For example, let's say I have a Foo.vue file like so:
<script lang="scss">
@import "./bar";
</script>
If I, after creating this file, make changes to the bar.scss file that is being imported, the dependency manager will cause Foo.vue to be updated as well. All good!
However, if I restart Meteor and make a change to bar.scss, Foo.vue will not be updated because the dependency manager doesn't reload the list of dependencies on startup. In order to update Foo.vue, I have to make some arbitrary change to the Foo.vue file. This becomes a big issue when you have a few base scss files that are being imported into nearly every component of your app.
Hum, this feature does exists, so this seems like a bug.
@nathantreid have you found a way to solve the problem?
I guess it's because Meteor cache compilation. Is there a way to also cache other informations from build plugins (like the file dependencies here)? @mitar @benjamn
I think so. I think there is some method on the plugin where you can return what to cache/watch. I think you can return from compileOneFile all the files which were a dependency for a given file?
I did something like that here: https://github.com/meteor/meteor/pull/9272
I don't see anything on the PR
I am just saying that I used that in compileOneFile method from the plugin. Maybe I am misunderstanding this issue? But this is how I informed Meteor what files to watch.
Reading through the issue again, I think I am adding noise. Please ignore.