-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 85d4d13
Showing
14 changed files
with
19,573 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
.DS_Store | ||
node_modules | ||
/dist | ||
|
||
|
||
# local env files | ||
.env.local | ||
.env.*.local | ||
|
||
# Log files | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
|
||
# Editor directories and files | ||
.idea | ||
.vscode | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# test | ||
|
||
## Project setup | ||
``` | ||
npm install | ||
``` | ||
|
||
### Compiles and hot-reloads for development | ||
``` | ||
npm run serve | ||
``` | ||
|
||
### Compiles and minifies for production | ||
``` | ||
npm run build | ||
``` | ||
|
||
### Lints and fixes files | ||
``` | ||
npm run lint | ||
``` | ||
|
||
### Customize configuration | ||
See [Configuration Reference](https://cli.vuejs.org/config/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
module.exports = { | ||
presets: [ | ||
'@vue/cli-plugin-babel/preset' | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Document</title> | ||
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/echarts.min.js"></script> | ||
</head> | ||
<body> | ||
<div id="main" style="width: 600px;height:400px;"></div> | ||
<script> | ||
// const pricesWs = new WebSocket('wss://ws.coincap.io/prices?assets=bitcoin,ethereum,monero,litecoin') | ||
// var a = 10; | ||
// pricesWs.onmessage = function (msg) { | ||
// console.log(a, 999); | ||
// // console.log(msg.data) | ||
// } | ||
const tradeWs = new WebSocket('wss://ws.coincap.io/trades/binance') | ||
|
||
tradeWs.onmessage = function (msg) { | ||
console.log(msg.data) | ||
} | ||
// 基于准备好的dom,初始化echarts实例 | ||
|
||
// var chartDom = document.getElementById('main'); | ||
// var myChart = echarts.init(chartDom); | ||
// var option; | ||
// option = { | ||
// xAxis: { | ||
// axisLine: { | ||
// lineStyle: { | ||
// // type: 'dashed' | ||
// } | ||
// }, | ||
// // 刻度 | ||
// axisTick: { | ||
// length: 5, | ||
// lineStyle: { | ||
// // type: 'dashed' | ||
// } | ||
// }, | ||
// axisLabel: { | ||
// formatter: '{value} kg', | ||
// align: 'center' | ||
// }, | ||
// nameTextStyle: { | ||
// align: 'center', | ||
// verticalAlign: 'middle', | ||
// padding: [3, 4, 5, 6], | ||
// width: 1000 | ||
// }, | ||
// // gridIndex: 1, | ||
// show: true, | ||
// position: 'bottom', | ||
// type: 'category', | ||
// name: '销售时间sdfdsfrsdfsrfsrfsdfsrfesrfsrf', | ||
// data: [1,2,3], | ||
// // nameLocation: 'middle' | ||
// }, | ||
// yAxis: [ | ||
// { | ||
// type: 'value', | ||
// name: '销售数量', | ||
// axisTick: { | ||
// length: 6, | ||
// lineStyle: { | ||
// type: 'dashed' | ||
// } | ||
// } | ||
// }, | ||
// { | ||
// type: 'value', | ||
// name: '销售金额' | ||
// } | ||
// ], | ||
// series: [ | ||
// { | ||
// data: [1,2,3,4], | ||
// type: 'line' | ||
// } | ||
// ] | ||
// } | ||
|
||
// myChart.setOption(option); | ||
|
||
</script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"compilerOptions": { | ||
"target": "es5", | ||
"module": "esnext", | ||
"baseUrl": "./", | ||
"moduleResolution": "node", | ||
"paths": { | ||
"@/*": [ | ||
"src/*" | ||
] | ||
}, | ||
"lib": [ | ||
"esnext", | ||
"dom", | ||
"dom.iterable", | ||
"scripthost" | ||
] | ||
} | ||
} |
Oops, something went wrong.