![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
前端
l-coder-dd
这个作者很懒,什么都没留下…
展开
-
react-router分散式路由外层组件格式
react-router分散式路由外层组件格式原创 2022-09-27 10:25:53 · 255 阅读 · 0 评论 -
vue3 在页面中引入其他页面报错,提示页面不存在
vue3 在页面中引入其他页面报错,提示页面不存在原创 2022-09-24 14:59:37 · 1036 阅读 · 0 评论 -
vue3.0支持jsx/tsx
jsx/tsx原创 2022-09-12 09:45:29 · 422 阅读 · 0 评论 -
element-plus样式修改
element-plus样式修改原创 2022-09-11 14:27:16 · 6104 阅读 · 0 评论 -
umijs(max)antdpro 添加页面无法铺满全屏
umijs(max)antdpro 添加页面无法铺满全屏原创 2022-09-09 17:15:51 · 574 阅读 · 0 评论 -
使用vite报错:error when starting dev server:Error: Cannot find module ‘unplugin-vue-components/vite‘
使用vite报错:error when starting dev server:Error: Cannot find module 'unplugin-vue-components/vite'原创 2022-07-01 16:45:56 · 5786 阅读 · 1 评论 -
vue tsx definComponent 自定义组件无法显示问题
vue tsx definComponent 自定义组件无法显示问题原创 2022-06-30 16:00:12 · 785 阅读 · 0 评论 -
div占满屏幕
前端div占满屏幕原创 2022-06-24 12:03:55 · 73 阅读 · 0 评论 -
react HOOKs useEffect()
useEffect(() => {}, []);useEffect(func, array);useEffectl第一个参数func是出发后要执行的方法第二个参数array是监听对象的集合,将需要根据变量值变化触发func的变量都保存到array中原创 2022-03-11 16:51:27 · 1107 阅读 · 0 评论 -
vue-cli创建项目
一 使用webpack1 vue init webpack my-project2 cd my-projectnpm install 包安装npm run dev开发启动3 npm run build 打包二 不使用webpackvue create my-project原创 2022-01-20 11:03:28 · 471 阅读 · 0 评论 -
react hooks 系列 memo,useCallback,useMemo防止子组件过渡渲染
React.memo():包裹子组件React.useCallback() :包裹方法函数React.useMemo():包裹对象 {“a”:“1”,“b”:“2”}原创 2021-12-29 10:50:11 · 565 阅读 · 0 评论 -
前端ui框架
react -- pc:antd系列ui ; 移动端:antd mobilevue -- pc:elementplus; 移动端:有赞vant,antd mobile混合开发ionic原创 2021-12-02 15:16:20 · 444 阅读 · 0 评论 -
MyBatis Generator
MyBatis Generator原创 2021-11-16 18:07:12 · 201 阅读 · 0 评论 -
使用 antd mobile v5.0.0-beta.25
使用import { NavBar, TabBar } from 'antd-mobile'语句时,项目报错These dependencies were not found:提示找不到 nav-bar,tab-bar,To install them, you can run: npm install --save antd-mobile/es/nav-bar antd-mobile/es/nav-bar/style antd-mobile/es/tab-bar antd-mobile/es/.原创 2021-11-11 10:32:07 · 981 阅读 · 1 评论 -
vue vuex router
import Vue from 'vue'import Vuex from 'vuex'import router from "../../router"import App from './App.vue'import iView from 'iview'import AxiosPlugin from "../MyAxiosPlugin"Vue.use(AxiosPlugin)Vue.use(Vuex)Vue.use(iView)const store = new Vuex.Stor.原创 2021-10-23 22:00:16 · 75 阅读 · 0 评论 -
react router集中式路由
import { routesArray } from './routerArray'import {renderRoutes, matchRoutes} from 'react-router-config';import {HashRouter} from 'react-router-dom';function App() { return(<HashRouter> {renderRoutes(routesArray)} </HashRouter>);}.原创 2021-10-23 19:26:02 · 484 阅读 · 0 评论 -
react router withRouter与@withRouter
withRouter与@withRouter包裹非路由组件,将match,location,history等路由信息添加到非路由组件的this.props中import {withRouter} from 'react-router';let app = ()=>{ return (<div></div>)}export default withRouter(app)//////////////////////////////////////@w原创 2021-10-21 19:22:53 · 136 阅读 · 0 评论 -
react router config 集中式路由管理(类似于vue-router)
1 npm install react-router-config2 import {renderRoutes, matchRoutes} from 'react-router-config';3 路由数组 let routes = [ ];4renderRoutes每次只渲染路由数组中的一层import { BrowserRouter } from 'react-router-dom'import { routesArray } from './routerArray'i..原创 2021-10-21 18:42:13 · 477 阅读 · 0 评论 -
react router 分散式路由管理
第二步 root节点包裹Router标签import { BrowserRouter } from 'react-router-dom'const states = { userState};ReactDOM.render( <Provider {...states}> <BrowserRouter> <Mainlayout /> </BrowserRouter > </Pr..原创 2021-10-21 18:21:48 · 119 阅读 · 0 评论 -
react-router 4及之后的版本之后不再使用this.props.children渲染组件,直接使用Route
react-router 4及之后的版本之后不再使用this.props.children渲染组件,直接使用Route原创 2021-10-21 18:06:21 · 168 阅读 · 0 评论 -
解决antdUI的layout布局无法占据整合界面
在css样式表中添加一下代码“#root,body,html { height: 100%;}.ant-layout { display: flex!important; width: 100%!important; min-height: 100%!important;}!important用来覆盖antdui原有的css属性值原创 2021-10-17 16:25:58 · 1521 阅读 · 1 评论 -
umi dva demo
modelimport {routerRedux} from 'dva/router'//routerRedux实现在effcts中路由跳转export default { namespace:"user", state:{ userInfo:{ name:"name0", age:"0" } }, subscription:{}, effects:{ * getUserInfo({payload},{call,put}){..原创 2021-10-07 16:55:57 · 248 阅读 · 0 评论 -
mobx6 基本使用demo
state类 ,action只对当前函数有效,,对嵌套调用的函数无效,需要使用runAction包裹import {observable,action,computed,makeObservable} from 'mobx'class UserState{ constructor() { makeObservable(this); } @observable name = "aaaa"; @observable age = 1;原创 2021-10-07 14:36:12 · 426 阅读 · 0 评论 -
umi + dva +hooks
umi + dva +hooks原创 2021-10-04 21:15:39 · 243 阅读 · 0 评论 -
mobx6,state更新后。react试图没有更新
mobx最新版本,state更新后不会自动刷新react试图,需要在state中添加makeObservableclass State{ constructor() { makeObservable(this); }}原创 2021-10-04 21:13:52 · 270 阅读 · 0 评论 -
Support for the experimental syntax ‘decorators-legacy‘ isn‘t currently enab
缺少插件,不支持装饰模式解决步骤1 npm install -D @babel/plugin-proposal-decorators2npm run eject(如不执行该命令,可能导致修改无法生效)3 修改package.json中的babel配置"babel": { "presets": [ "react-app" ], "plugins": [ [ "@babel/plugin-proposal-decorat...原创 2021-10-02 14:24:25 · 425 阅读 · 0 评论 -
前端flex布局与grid网格布局
前端flex布局与grid网格布局,原创 2020-06-01 10:05:18 · 409 阅读 · 0 评论 -
vue下载excel---使用blob数据类型
axios.post(url,params,{responseType: 'blob'}).then(res => { let blob = new Blob([res]) let de = document.createElement('a'); let hrefLink = window.URL.createObjectURL(blob); //创建下载的链接 de.href = hrefLink ; de.download = 'excelName.xls'; //下载后.原创 2020-06-01 09:54:13 · 1446 阅读 · 0 评论 -
<fmt>标签
<fmt:message key="">可以从本地pei'配置文件中获取value比如:xxx.perporty文件原创 2019-02-20 21:46:16 · 114 阅读 · 0 评论 -
Object.defineProperty(obj, prop, descriptor)
Object.defineProperty(obj, prop, descriptor)实现双向绑定功能原创 2018-08-12 11:35:40 · 371 阅读 · 0 评论