去掉console
This commit is contained in:
parent
d7fb3356e8
commit
647be6fd8f
@ -1,5 +1,7 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
presets: [
|
presets: [
|
||||||
'@vue/cli-plugin-babel/preset'
|
'@vue/cli-plugin-babel/preset'
|
||||||
]
|
],
|
||||||
|
plugins: ['transform-remove-console']
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
"@vue/cli-service": "~4.4.0",
|
"@vue/cli-service": "~4.4.0",
|
||||||
"@vue/eslint-config-standard": "^5.1.2",
|
"@vue/eslint-config-standard": "^5.1.2",
|
||||||
"babel-eslint": "^10.1.0",
|
"babel-eslint": "^10.1.0",
|
||||||
|
"babel-plugin-transform-remove-console": "^6.9.4",
|
||||||
"eslint": "^6.7.2",
|
"eslint": "^6.7.2",
|
||||||
"eslint-plugin-import": "^2.20.2",
|
"eslint-plugin-import": "^2.20.2",
|
||||||
"eslint-plugin-node": "^11.1.0",
|
"eslint-plugin-node": "^11.1.0",
|
||||||
|
File diff suppressed because one or more lines are too long
@ -13,20 +13,19 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import echarts from 'echarts'
|
import echarts from 'echarts'
|
||||||
import _ from 'lodash'
|
import _ from 'lodash'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {},
|
||||||
},
|
data() {
|
||||||
data () {
|
return {
|
||||||
return {
|
options: {
|
||||||
options: {
|
title: {
|
||||||
title: {
|
text: '用户来源'
|
||||||
text: '用户来源'
|
},
|
||||||
},
|
tooltip: {
|
||||||
tooltip: {
|
trigger: 'axis',
|
||||||
trigger: 'axis',
|
|
||||||
axisPointer: {
|
axisPointer: {
|
||||||
type: 'cross',
|
type: 'cross',
|
||||||
label: {
|
label: {
|
||||||
@ -58,9 +57,7 @@ export default {
|
|||||||
const chart = echarts.init(document.querySelector('#main'))
|
const chart = echarts.init(document.querySelector('#main'))
|
||||||
this.$http.get('reports/type/1').then(response => {
|
this.$http.get('reports/type/1').then(response => {
|
||||||
const res = response.data
|
const res = response.data
|
||||||
console.log(res.data, this.options)
|
|
||||||
const r = _.merge(res.data, this.options)
|
const r = _.merge(res.data, this.options)
|
||||||
console.log(r)
|
|
||||||
chart.setOption(r)
|
chart.setOption(r)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
10
yarn.lock
10
yarn.lock
@ -1695,6 +1695,11 @@ babel-plugin-dynamic-import-node@^2.3.3:
|
|||||||
dependencies:
|
dependencies:
|
||||||
object.assign "^4.1.0"
|
object.assign "^4.1.0"
|
||||||
|
|
||||||
|
babel-plugin-transform-remove-console@^6.9.4:
|
||||||
|
version "6.9.4"
|
||||||
|
resolved "https://registry.npm.taobao.org/babel-plugin-transform-remove-console/download/babel-plugin-transform-remove-console-6.9.4.tgz#b980360c067384e24b357a588d807d3c83527780"
|
||||||
|
integrity sha1-uYA2DAZzhOJLNXpYjYB9PINSd4A=
|
||||||
|
|
||||||
babel-runtime@6.x:
|
babel-runtime@6.x:
|
||||||
version "6.26.0"
|
version "6.26.0"
|
||||||
resolved "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe"
|
resolved "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe"
|
||||||
@ -5738,6 +5743,11 @@ npm-run-path@^4.0.0:
|
|||||||
dependencies:
|
dependencies:
|
||||||
path-key "^3.0.0"
|
path-key "^3.0.0"
|
||||||
|
|
||||||
|
nprogress@^0.2.0:
|
||||||
|
version "0.2.0"
|
||||||
|
resolved "https://registry.npm.taobao.org/nprogress/download/nprogress-0.2.0.tgz#cb8f34c53213d895723fcbab907e9422adbcafb1"
|
||||||
|
integrity sha1-y480xTIT2JVyP8urkH6UIq28r7E=
|
||||||
|
|
||||||
nth-check@^1.0.2, nth-check@~1.0.1:
|
nth-check@^1.0.2, nth-check@~1.0.1:
|
||||||
version "1.0.2"
|
version "1.0.2"
|
||||||
resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.2.tgz#b2bd295c37e3dd58a3bf0700376663ba4d9cf05c"
|
resolved "https://registry.yarnpkg.com/nth-check/-/nth-check-1.0.2.tgz#b2bd295c37e3dd58a3bf0700376663ba4d9cf05c"
|
||||||
|
Loading…
Reference in New Issue
Block a user