不用cdn了。本地部署本地使用直接把js借过来快多了,起码每次省半秒,快的时候省好几秒。
This commit is contained in:
parent
6261d3eba1
commit
d3bd8d6d15
@ -4,7 +4,7 @@
|
|||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>习题识别工具</title>
|
<title>习题识别工具</title>
|
||||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/element-plus/dist/index.css">
|
<link rel="stylesheet" href="static/element-plus/index.css">
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -55,8 +55,8 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script src="https://cdn.jsdelivr.net/npm/vue@3"></script>
|
<script src="static/vue@3.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/element-plus"></script>
|
<script src="static/element-plus.js"></script>
|
||||||
<script>
|
<script>
|
||||||
const {createApp} = Vue;
|
const {createApp} = Vue;
|
||||||
const {ElButton, ElRow, ElCol} = ElementPlus;
|
const {ElButton, ElRow, ElCol} = ElementPlus;
|
||||||
|
|||||||
73
html/static/element-plus.js
Normal file
73
html/static/element-plus.js
Normal file
File diff suppressed because one or more lines are too long
1
html/static/element-plus/index.css
Normal file
1
html/static/element-plus/index.css
Normal file
File diff suppressed because one or more lines are too long
20
html/static/vue@3.js
Normal file
20
html/static/vue@3.js
Normal file
File diff suppressed because one or more lines are too long
@ -4,7 +4,7 @@
|
|||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>接收终端</title>
|
<title>接收终端</title>
|
||||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/element-plus/dist/index.css">
|
<link rel="stylesheet" href="static/element-plus/index.css">
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -99,8 +99,8 @@
|
|||||||
></el-image-viewer>
|
></el-image-viewer>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script src="https://cdn.jsdelivr.net/npm/vue@3"></script>
|
<script src="static/vue@3.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/element-plus"></script>
|
<script src="static/element-plus.js"></script>
|
||||||
<script>
|
<script>
|
||||||
const {createApp} = Vue;
|
const {createApp} = Vue;
|
||||||
const {ElInput, ElButton, ElRow, ElCol, ElMessage, ElImageViewer} = ElementPlus;
|
const {ElInput, ElButton, ElRow, ElCol, ElMessage, ElImageViewer} = ElementPlus;
|
||||||
|
|||||||
@ -4,7 +4,7 @@
|
|||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>习题上传</title>
|
<title>习题上传</title>
|
||||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/element-plus/dist/index.css">
|
<link rel="stylesheet" href="static/element-plus/index.css">
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -125,9 +125,8 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script src="https://cdn.jsdelivr.net/npm/vue@3"></script>
|
<script src="static/vue@3.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/element-plus"></script>
|
<script src="static/element-plus.js"></script>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
|
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
const {createApp} = Vue;
|
const {createApp} = Vue;
|
||||||
|
|||||||
5
main.py
5
main.py
@ -119,3 +119,8 @@ async def test():
|
|||||||
@app.get("/favicon.ico", response_class=FileResponse)
|
@app.get("/favicon.ico", response_class=FileResponse)
|
||||||
async def favicon():
|
async def favicon():
|
||||||
return FileResponse("html/favicon.ico")
|
return FileResponse("html/favicon.ico")
|
||||||
|
|
||||||
|
|
||||||
|
@app.get("/static/{path:path}", response_class=FileResponse)
|
||||||
|
async def static(path: str):
|
||||||
|
return FileResponse(f"html/static/{path}")
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user