From 304f819d3e9b2498ebdb70b99b632cda67725a52 Mon Sep 17 00:00:00 2001
From: 李 <344137771@qq.com>
Date: Sun, 31 May 2026 17:57:32 +0800
Subject: [PATCH] 1
---
vite.config.js | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/vite.config.js b/vite.config.js
index 0f9037d..5f0dfd3 100644
--- a/vite.config.js
+++ b/vite.config.js
@@ -7,6 +7,7 @@
import { visualizer } from 'rollup-plugin-visualizer'
import legacy from '@vitejs/plugin-legacy';
+const scss_path = `@/assets/theme/index.scss`
const isVisualizer = process.env.VISUALIZER === 'show'
export default defineConfig({
base: '', //H5打包用
@@ -26,6 +27,7 @@
preprocessorOptions: {
scss: {
additionalData: `@import "@/assets/css/variable.scss";`
+ // additionalData: `@import "@/assets/css/variable.scss";@import "${scss_path}";`
},
}
},
@@ -42,6 +44,12 @@
// rewrite: (path) => path.replace(/^\/wap/, ""),
secure: false
},
+ "/newsapi-api": {
+ target: "https://newsapi.org",
+ changeOrigin: true,
+ rewrite: (path) => path.replace(/^\/newsapi-api/, ''),
+ secure: true
+ },
},
},
resolve: {
--
Gitblit v1.9.3