vuejs / vue-migration-helper

CLI tool to aid in migration from Vue 1.x to 2.0
594 stars 59 forks source link

helper is also reading unrelated files ex. .scss #25

Closed rhysburnie closed 8 years ago

rhysburnie commented 8 years ago

The helper is reading files that aren't relevant.

For example:

 Rename $index to index and explicity declare it (e.g. v-for="(item, index) in items")
  Line 9: src/assets/scss/_font-loader.scss

the $index in that file has nothing to do with vue its a sass variable in a sass function

rhysburnie commented 8 years ago

Also in another native js file that happened to have a function named init was receiving this message: Replace init with beforeCreate - its not in any way a vue file.

i.e.

export function init() {
  // stuff...
}
rhysburnie commented 8 years ago

Also I had some markdown documentation for my project with the line:

if all else fails the app will fallback to use fake device data (which is the case in development...

migration tool says Replace the data route hook with a watcher that reacts to $route changes just because it happens to have the word data in the paragraph

rhysburnie commented 8 years ago
<input type="tel" v-model="userPhone" placeholder="Phone number"

warns: Refactor number to a v-model modifier: v-model.number="userPhone"

only because the placeholder has the word number in it, surely should only be a message if you were using the number attr

chrisvfritz commented 8 years ago

Thanks for reporting these! If you update the migration helper, I believe they should all be fixed now. Can you confirm?

chrisvfritz commented 8 years ago

@rhysburnie Just pinging on this. Do you still experience any of these issues with the latest update?

rhysburnie commented 8 years ago

In the process of using the update, a few of the issues exist will post as I come across them.

One of them is Im getting this in a markdown file Replace route.mixin with route.meta.mixin

The line in the file is simply linking to another markdown file called: track-route.mixin.md

chrisvfritz commented 8 years ago

@rhysburnie Thanks! That one should now be fixed too.

chrisvfritz commented 8 years ago

@rhysburnie Closing this for now, as I believe all the items you brought up should now be resolved. If you find anything else, feel free to open new issues. 😃 Thanks for your help!