Skip to content

Commit

Permalink
增加 wx 的 alias 配置
Browse files Browse the repository at this point in the history
  • Loading branch information
F-loat committed Mar 22, 2018
1 parent a730d2b commit c3ef6e7
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 2 deletions.
1 change: 0 additions & 1 deletion .eslintrc.js
Expand Up @@ -29,7 +29,6 @@ module.exports = {
globals: {
App: true,
Page: true,
wx: true,
getApp: true,
getPage: true
}
Expand Down
3 changes: 2 additions & 1 deletion build/webpack.base.conf.js
Expand Up @@ -31,9 +31,10 @@ module.exports = {
resolve: {
extensions: ['.js', '.vue', '.json'],
alias: {
'@': resolve('src'),
vue: 'mpvue',
flyio: 'flyio/dist/npm/wx',
'@': resolve('src')
wx: resolve('src/utils/wx')
},
symlinks: false
},
Expand Down
1 change: 1 addition & 0 deletions src/pages/news/list/index.vue
Expand Up @@ -15,6 +15,7 @@
</template>

<script>
import wx from 'wx'
import { mapState, mapActions } from 'vuex'
import newsItem from '@/components/news-item'
Expand Down
1 change: 1 addition & 0 deletions src/pages/quanzi/list/index.vue
Expand Up @@ -18,6 +18,7 @@
</template>

<script>
import wx from 'wx'
import { mapState, mapActions } from 'vuex'
export default {
Expand Down
1 change: 1 addition & 0 deletions src/utils/request.js
@@ -1,3 +1,4 @@
import wx from 'wx'
import Fly from 'flyio'

const request = new Fly()
Expand Down
2 changes: 2 additions & 0 deletions src/utils/wx.js
@@ -0,0 +1,2 @@
/* eslint-disable */
export default wx

0 comments on commit c3ef6e7

Please sign in to comment.