Skip to content

Commit 48fb5dc

Browse files
asumarankazupon
authored andcommitted
Move import at the top to prevent eslint error (#478)
By doing this it fixes the following error ``` ERROR Failed to compile with 1 errors error in ./src/router/index.js ✘ https://google.com/#q=import%2Ffirst Import in body of module; reorder to top /Users/asumaran/www/my-project/src/router/index.js:6:1 import Hello from 'components/Hello'; ^ ✘ 1 problem (1 error, 0 warnings) ```
1 parent ca9faaf commit 48fb5dc

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

template/src/router/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
import Vue from 'vue'{{#if_eq lintConfig "airbnb"}};{{/if_eq}}
22
import Router from 'vue-router'{{#if_eq lintConfig "airbnb"}};{{/if_eq}}
3+
import Hello from 'components/Hello'{{#if_eq lintConfig "airbnb"}};{{/if_eq}}
34

45
Vue.use(Router){{#if_eq lintConfig "airbnb"}};{{/if_eq}}
56

6-
import Hello from 'components/Hello'{{#if_eq lintConfig "airbnb"}};{{/if_eq}}
7-
87
export default new Router({
98
routes: [
109
{

0 commit comments

Comments
 (0)