release:公开仓库

This commit is contained in:
zy7y
2022-09-19 22:59:27 +08:00
parent 5566e6693b
commit ebf5b77788
13 changed files with 37 additions and 17 deletions

View File

@@ -1,2 +1,2 @@
VITE_BASE_URL = /api
VITE_WEBSOCKET = /socket
VITE_WS = ws://localhost:8000/ws

View File

@@ -5,7 +5,7 @@ import EachartView from '@/components/echart/eachart-view.vue'
import MarkdownView from '@/components/markdown/preview-view.vue'
/** websocket */
let ws = new WebSocket('ws://localhost:8000/ws')
let ws = new WebSocket(import.meta.env.VITE_WS)
// 响应式数据
const data = reactive({

View File

@@ -25,10 +25,6 @@ export default defineConfig({
target: 'http://localhost:8000',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
},
'/socket': {
target: 'ws://localhost:8000/ws',
ws: true
}
}
}