Compare commits
5 Commits
8ce1c87dff
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| aa0e71ce94 | |||
| b77f90559a | |||
| a1828a0aba | |||
| cba1c5adb9 | |||
| 095626b857 |
4
.env
4
.env
@@ -1 +1,3 @@
|
|||||||
WEB_URL=http://localhost:8000
|
PUBLIC_WEB_URL=http://localhost:8000
|
||||||
|
PUBLIC_BASE_URL=http://localhost:8000/api
|
||||||
|
PUBLIC_ADMIN_URL=http://localhost:8000/admin
|
||||||
@@ -1 +1,3 @@
|
|||||||
WEB_URL=https://web.xuyue.cc
|
PUBLIC_WEB_URL=https://web.xuyue.cc
|
||||||
|
PUBLIC_ADMIN_URL=https://web.xuyue.cc/admin
|
||||||
|
PUBLIC_BASE_URL=https://web.xuyue.cc/api
|
||||||
3
.env.staging
Normal file
3
.env.staging
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
PUBLIC_WEB_URL=http://10.13.114.114:91
|
||||||
|
PUBLIC_ADMIN_URL=http://10.13.114.114:91/admin
|
||||||
|
PUBLIC_BASE_URL=http://10.13.114.114:91/api
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
<html lang="zh-Hans-CN">
|
<html lang="zh-Hans-CN">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<link rel="shortcut icon" href="/favicon.ico" />
|
<link rel="shortcut icon" href="/noto--honeybee.ico" />
|
||||||
<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="/normalize.min.css" />
|
<link rel="stylesheet" href="/normalize.min.css" />
|
||||||
|
|||||||
1223
package-lock.json
generated
1223
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
35
package.json
35
package.json
@@ -1,40 +1,41 @@
|
|||||||
{
|
{
|
||||||
"name": "web",
|
"name": "web",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "0.2.0",
|
"version": "0.3.0",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "rsbuild dev",
|
"start": "rsbuild dev",
|
||||||
"build": "rsbuild build",
|
"build": "rsbuild build",
|
||||||
|
"build:staging": "rsbuild build --env-mode staging",
|
||||||
"fmt": "prettier --write src/"
|
"fmt": "prettier --write src/"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@codemirror/lang-css": "^6.3.1",
|
"@codemirror/lang-css": "^6.3.1",
|
||||||
"@codemirror/lang-html": "^6.4.9",
|
"@codemirror/lang-html": "^6.4.11",
|
||||||
"@codemirror/lang-javascript": "^6.2.4",
|
"@codemirror/lang-javascript": "^6.2.4",
|
||||||
"@vueuse/core": "^13.5.0",
|
"@vueuse/core": "^14.1.0",
|
||||||
"axios": "^1.10.0",
|
"axios": "^1.13.2",
|
||||||
"codemirror": "^6.0.2",
|
"codemirror": "^6.0.2",
|
||||||
"copy-text-to-clipboard": "^3.2.0",
|
"copy-text-to-clipboard": "^3.2.2",
|
||||||
"github-markdown-css": "^5.8.1",
|
"github-markdown-css": "^5.8.1",
|
||||||
"highlight.js": "^11.11.1",
|
"highlight.js": "^11.11.1",
|
||||||
"marked": "^16.0.0",
|
"marked": "^17.0.1",
|
||||||
"marked-alert": "^2.1.2",
|
"marked-alert": "^2.1.2",
|
||||||
"marked-code-preview": "^1.3.7",
|
"marked-code-preview": "^1.3.7",
|
||||||
"marked-highlight": "^2.2.2",
|
"marked-highlight": "^2.2.3",
|
||||||
"md-editor-v3": "^5.8.1",
|
"md-editor-v3": "^6.2.1",
|
||||||
"naive-ui": "^2.42.0",
|
"naive-ui": "^2.43.2",
|
||||||
"vue": "^3.5.17",
|
"vue": "^3.5.26",
|
||||||
"vue-codemirror": "^6.1.1",
|
"vue-codemirror": "^6.1.1",
|
||||||
"vue-router": "^4.5.1"
|
"vue-router": "^4.6.4"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@iconify/vue": "^5.0.0",
|
"@iconify/vue": "^5.0.0",
|
||||||
"@rsbuild/core": "^1.4.6",
|
"@rsbuild/core": "^1.6.15",
|
||||||
"@rsbuild/plugin-vue": "^1.1.0",
|
"@rsbuild/plugin-vue": "^1.2.2",
|
||||||
"@vue/tsconfig": "^0.7.0",
|
"@vue/tsconfig": "^0.8.1",
|
||||||
"prettier": "^3.6.2",
|
"prettier": "^3.7.4",
|
||||||
"typescript": "^5.8.3",
|
"typescript": "^5.9.3",
|
||||||
"unplugin-vue-components": "^28.8.0"
|
"unplugin-vue-components": "^30.0.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
BIN
public/noto--honeybee.ico
Normal file
BIN
public/noto--honeybee.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 200 KiB |
@@ -29,7 +29,7 @@ export default defineConfig({
|
|||||||
server: {
|
server: {
|
||||||
proxy: {
|
proxy: {
|
||||||
"/media": {
|
"/media": {
|
||||||
target: process.env.WEB_URL,
|
target: process.env.PUBLIC_WEB_URL,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
4
src/env.d.ts
vendored
4
src/env.d.ts
vendored
@@ -1,5 +1,7 @@
|
|||||||
interface ImportMetaEnv {
|
interface ImportMetaEnv {
|
||||||
readonly MODE: "production" | "development" | "none"
|
readonly PUBLIC_WEB_URL: string
|
||||||
|
readonly PUBLIC_BASE_URL: string
|
||||||
|
readonly PUBLIC_ADMIN_URL: string
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ImportMeta {
|
interface ImportMeta {
|
||||||
|
|||||||
@@ -35,15 +35,9 @@ export const STORAGE_KEY = {
|
|||||||
FONTSIZE: "web-fontsize",
|
FONTSIZE: "web-fontsize",
|
||||||
}
|
}
|
||||||
|
|
||||||
export const ADMIN_URL =
|
export const ADMIN_URL = import.meta.env.PUBLIC_ADMIN_URL
|
||||||
import.meta.env.MODE === "development"
|
|
||||||
? "http://localhost:8000/admin"
|
|
||||||
: "https://web.xuyue.cc/admin"
|
|
||||||
|
|
||||||
export const BASE_URL =
|
export const BASE_URL = import.meta.env.PUBLIC_BASE_URL
|
||||||
import.meta.env.MODE === "development"
|
|
||||||
? "http://localhost:8000/api"
|
|
||||||
: "https://web.xuyue.cc/api"
|
|
||||||
|
|
||||||
export enum TASK_TYPE {
|
export enum TASK_TYPE {
|
||||||
Tutorial = "tutorial",
|
Tutorial = "tutorial",
|
||||||
|
|||||||
Reference in New Issue
Block a user