上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 97 下一页
摘要: 案例 <template> <div class="container"> <div class="screen" ref="screen"> <!-- 顶部 --> <div class="top"></div> <!-- 底部 --> <div class="bottom"> <!-- 左侧 - 阅读全文
posted @ 2025-04-07 18:22 市丸银 阅读(71) 评论(0) 推荐(0)
摘要: 1、下载 npm i nprogress 2、引入 import NProgress from 'nprogress' import 'nprogress/nprogress.css' // 基础样式 3、使用 NProgress.start() // 开始进度条 NProgress.done() 阅读全文
posted @ 2025-03-30 10:17 市丸银 阅读(83) 评论(0) 推荐(0)
摘要: let isFull = document.fullscreenElement if(!isFull){ // 不是全屏,设置全屏 document.documentElement.requestFullscreen() } else { // 全屏,退出全屏 document.exitFullsc 阅读全文
posted @ 2025-03-29 13:15 市丸银 阅读(13) 评论(0) 推荐(0)
摘要: 1、引入 import {nextTick} from "vue" 2、使用 nextTick(() => { // 内容 }) 阅读全文
posted @ 2025-03-29 13:02 市丸银 阅读(17) 评论(0) 推荐(0)
摘要: 一、册全局组件 el-icon // main.ts // 如果您正在使用CDN引入,请删除下面一行。 import * as ElementPlusIconsVue from '@element-plus/icons-vue' const app = createApp(App) for (con 阅读全文
posted @ 2025-03-28 10:07 市丸银 阅读(46) 评论(0) 推荐(0)
摘要: 一、安装依赖 npm install sass-embedded 二、配置全局变量 1、新建文件 src/styles/variables.scss 2、配置Vite 修改 vite.config.js css: { preprocessorOptions: { scss: { additional 阅读全文
posted @ 2025-03-22 17:21 市丸银 阅读(857) 评论(0) 推荐(0)
摘要: 一、自定义插件 参考: 1、创建 src/components/index.ts 2、内容 import SvgIcon from './SvgIcon.vue' // 全部全局组件 const allGloablComponent = { SvgIcon, } export default { i 阅读全文
posted @ 2025-03-22 16:41 市丸银 阅读(187) 评论(0) 推荐(0)
摘要: 一、新建文件 .env.development .env.production .env.test 开发、生产、测试 二、文件内容 1、开发 # 变量必须以 VITE_ 为前缀才能暴露给外部读取 NODE_ENV = 'development' VITE_APP_TITLE = 'developme 阅读全文
posted @ 2025-03-22 11:13 市丸银 阅读(132) 评论(0) 推荐(0)
摘要: 一、SVG图标配置 1、安装依赖 npm install vite-plugin-svg-icons 2、在vite.config.ts中配置插件 import { fileURLToPath, URL } from 'node:url' import VueSetupExtend from 'vi 阅读全文
posted @ 2025-03-22 10:54 市丸银 阅读(286) 评论(0) 推荐(0)
摘要: 1、文件 vite.config.ts 2、注释 阅读全文
posted @ 2025-03-22 09:48 市丸银 阅读(474) 评论(0) 推荐(0)
上一页 1 ··· 12 13 14 15 16 17 18 19 20 ··· 97 下一页