assetsInclude: ['**/*.gltf'],//指定额外的 picomatch 模式 作为静态资源处理logLevel: 'info',//调整控制台输出的级别 'info' | 'warn' | 'error' | 'silent'clearScreen:true,//设为 false 可以避免 Vite 清屏而错过在终端中打印某些关键信息envDir: '/',//用于加载 .env 文件的目录envPrefix: []...
const appInfo = process.versions; 打包 这个倒是没什么好讲的了,主要还是在vue.config.js文件中进行配置一下,然后使用命令yarn electron:build即可,当然了,还有一个打包前清空的旧的打包文件夹的脚本 deleteBuild.js 打包清空dist_electron旧的打包内容,因为eslint的原因,这里就用eslint-disable关掉了几个 原理...
app.use(express.static(path.join(__dirname,'public'))) app.use(bodyParser.urlencoded({extended:false})) app.use(bodyParser.json()) app.get('/a',function(req, res) {console.log(req.query) res.send({"id":1,"name":"张三"}) }) app.listen(3000,function() {console.lo...
vue配置微服务多个模块 vue微服务化 思路: 1.登录认证oauth/token拦截器 2找到user信息 3.利用user字段得到token,返回赋值给session 4请求权限信息,网管拦截 ,用token去经过网关解析成id 5、跳转微服务getinfo,获取id查询用户权限角色。 开发技巧:代码一点一点的加,一点一点的测试,如果错了可以返回上一步。有时候加多...
Vue 脚手架工具 vue-cli 使用 webpack 进行打包,开发时可以启动本地开发服务器,实时预览。因为需要对整个项目文件进行打包,开发服务器启动缓慢 而对于开发时文件修改后的热更新 HMR 也存在同样的问题 Webpack 的热更新会以当前修改的文件为入口重新 build 打包,所有涉及到的依赖也都会被重新加载一次 ...
app.use(bodyParser.urlencoded({ extended:true })) app.use("/api",router); app.listen(3000,() =>{ console.log("server running at port 3000"); }) 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. const express = require("express"); ...
use(bodyParser.json()) app.get('/a', function(req, res) { console.log(req.query) res.send({ "id": 1, "name": "张三" }) }) app.listen(3000, function() { console.log('app is runing...') }) 请求 写法① 如果使用 Axios 的 POST 请求的简写形式,需要将数据以 JSON 格式传递。
"parser": "@typescript-eslint/parser" }, "plugins": ["vue", "prettier"], "rules": { "semi": ["warn", "never"] }, "settings": {} } 重启一下项目就可以了。 user.ts文件 这个文件主要是用户的一些状态信息。 import { defineStore } from "pinia"; ...
eslint-plugin-vue@latest @typescript-eslint/eslint-plugin@latest @typescript-eslint/parser@latest ? Would you like to install them now with npm? (Y/n) y 修改eslint配置,·.eslintrc.js,规则rules可以根据自己的喜欢配置 eslint.org/docs/user-g…[4] ...
pnpm i eslint-plugin-vue @typescript-eslint/parser @typescript-eslint/eslint-plugin -D 修改项目根目录下的.eslintrc.json配置文件; {"env":{"browser":true,"es2021":true,"node":true,"vue/setup-compiler-macros":true},"extends":["plugin:vue/vue3-essential","eslint:recommended","prettier...