- 博客(5)
- 收藏
- 关注
原创 vue自动生成路由
vue自动生成路由1. 安装自动生成路由的包npm i vue-auto-router2 -S2.使用import {autoRouter} from 'vue-auto-router2'const router = new VueRouter({...}) const routes = autoRouter({ views: require.context('./pages', true, /.*\.vue$/)})rou
2020-09-19 18:28:42 785
原创 vue js项目升级typescript
vue 老旧项目升级typescript先装包npm i typescript ts-loader @types/webpack-env -D创建tsconfig.json文件{ "compilerOptions": { "sourceMap": true, "strict": true }, "include": ["src/**/*"],}创建类型声明文件index.d.tsdeclare module '*.vue'{ import Vue from 'vue
2020-08-23 00:18:53 1638
原创 moduleFederation 使用
webpack5 moduleFederation 使用简介:在hostApp中暴露要给其他应用使用的模块,其他应用(clientApp)引入hostApp暴露的文件。在clientApp中像使用本地模块一样使用远程模块。HostApp和ClientApp 可互为host/client。即同一个应用,可同时提供/使用远程模块。上代码:依赖 package.json:{ // ... otherConfig devDependencies:{ // ... otherDevDepend
2020-08-21 11:22:24 1310
原创 nodejs中使用redis
1.安装redis地址:https://github.com/MSOpenTech/redis/releases解压到c盘,文件夹重命名为 redis命令行进入到解压后的目录运行.\redis-server.exe 运行后不要关闭这个窗口2.创建nodejs工程使用expressnpm iredis -S创建db/index.js文件,内容:con...
2019-04-28 16:14:58 634
原创 nginx配置websocket代理 http/https
Nginx配置http { ... #other config ... map $http_upgrade $connection_upgrade { default upgrade; '' close; } upstream websocket { server 127.0.0.1:8...
2019-02-18 17:37:18 4405
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人