element-plus element vue3 plus

Vue3| Pinia 的语法

Pinia 是 Vue 的最新 状态管理工具,是 Vuex 的替代品 Pinia 的优势: 1. 提供更简单的 API(去掉了 mutation) 2. 提供符合 组合式风格的 API(和 Vue3 新语法统一) 3. 去掉了 modules 的概念,每一个 store 都是一个独立的模块 4. 配 ......
语法 Pinia Vue3 Vue

Vue3| 组合式 API——provide 和 inject

作用和场景:顶层组件向任意的底层组件 传递数据和方法,实现 跨层组件通信 跨层传递普通数据 步骤: 1. 顶层组件通过 provide 函数提供数据 provide ( ' key ' , 顶层组件中的数据 ) 2. 底层组件通过 inject 函数获取数据 const message = inje ......
provide inject Vue3 Vue API

Vue3| 模板引用、defineExpose宏函数

模板引用的概念:通过 ref 标识 获取真实的 dom对象或者组件实例对象 使用: 1. 调用 ref 函数生成一个 ref 对象 <script setup> import { ref } from 'vue' const h1Ref = ref (null) </script> 2. 通过 re ......
defineExpose 函数 模板 Vue3 Vue

Vue3| 组合式 API 下的 子传父

步骤: 1. 子组件内部通过 emit 方法触发事件 ① 通过 defineEmits 编译器宏生成 emit 方法 <script setup> const emit = defineEmits ([ 'get-message' ]) // get-message:可以触发的事件 </script ......
Vue3 Vue API

Vue3| 组合式 API 下的父传子

步骤: 一、父给子传 写死的值 1. 父组件中给子组件 以添加属性的方式传值 <script setup> import sonComVue from './son-com.vue' // 局部注册 </script> <template> <sonComVue message = "黑马程序员"> ......
Vue3 Vue API

Vue3| 组合式API——computed 计算属性函数

计算属性基本思想和 Vue2 的完全一致,组合式 API 下的计算属性只是修改了写法 核心步骤: 1. 导入 computed 函数 <script setup> import { computed } from 'vue' </script> 2. 执行函数 在回调参数中 return 基于响应式 ......
函数 computed 属性 Vue3 Vue

Vue3| 组合式API——reactive 和 ref 函数

Vue中默认的数据并不是响应式的,如果我们希望数据是响应式的,则需要通过 reactive 或者 ref 进行处理。 reactive (): 作用:接收 对象类型的数据作为参数传入 并返回一个 响应式对象 reactive 不能处理简单类型的数据 reactive 使用步骤: 1. 在 <scri ......
函数 reactive Vue3 Vue API

Vue3| 组合式 API——setup 选项

组合式 API:一系列函数,有时需要调用这些函数编写组件逻辑。 setup 是组合式 API 的入口,先写 setup,才能往里边写组合式 API 的函数 setup 的执行时机会比 beforeCreate 生命周期钩子还要早,因此 setup 函数中获取不到 this setup 选项的写法:( ......
setup Vue3 Vue API

定位元素封装find_element(增加显性等待等)

封装 # find_elementUtil.py import os import time from selenium.webdriver.support import expected_conditions as EC from appium.webdriver.common.appiumby ......
find_element 元素 element find

Vue3 - watch 监听路由状态变化切换下一个页面 watch 函数还在执行

描述 你可能会通过 watch 函数监听路由变化,当路由参数发生变化之后,重新调用 fetchData 获取数据渲染页面。即,同路由页面切换。 但是,遇到了 A 页面切换到 B 页面时,A 页面的 watch 会被触发,导致报错。这是因为进入其他页面之前,你没有清除这个 watch 监听。 虽然随着 ......
watch 路由 函数 状态 页面

Vue3| create-vue 脚手架工具

create-vue 是 Vue 官方新的脚手架工具,底层切换到了 vite(下一代构建工具),为开发提供极速响应 使用 create-vue 创建项目: 1. 前提环境条件: 已安装 16.0 或更高版本的 Node.js(node -v) 2. 创建一个 Vue 应用:npm init vue ......
脚手架 create-vue 工具 create Vue3

【前端开发】vue3+vite项目部分优化

1、使用rollup-plugin-visualizer 可视化分析包 npm i rollup-plugin-visualizer -S 在vite.config.js中引入 在 plugins里面 然后执行npm run build就自动打开可视化分析 2 、 CDN加速 在vite.confi ......
前端 部分 项目 vue3 vite

Element type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got undefined

原因就是组件引入错误,应该是 import {BillReverse} form '../xx' 写成了 import Reverse from '../xx' 两个错误 1. 没写大括号 2. 组件名错误 如何从打包后的文件分析导出内容格式,待解决 ......
components composite for undefined expected

不好意思,Mybatis Plus 该换了!

使用fluent mybatis可以不用写具体的xml文件,通过java api可以构造出比较复杂的业务sql语句,做到代码逻辑和sql逻辑的合一。 不再需要在Dao中组装查询或更新操作,在xml或mapper中再组装参数。那对比原生Mybatis, Mybatis Plus或者其他框架,Fluen ......
不好 意思 Mybatis Plus

SpringBoot 1项目创建及Mybatis-plus实现数据增删改查

一. 项目创建及配置 1.项目创建 点击finish完成创建 pom.xml 加上以下依赖 <dependency> <groupId>com.baomidou</groupId> <artifactId>mybatis-plus-boot-starter</artifactId> <version ......

element表格的表头添加*星号

vue怎么实现element表格里表头信息提示功能?第一、给el-table添加:header-cell-class-name <el-table :header-cell-class-name="func"></el-table> 第二、在vue的methods中编写方法 // 给头部添加星星 f ......
表头 星号 表格 element

element-ui 解决 table 里包含表单验证

实际项目中的场景,需要在table里做表单的验证,如图效果: 其实问题关键就在于如何给el-form-item动态绑定prop :prop="'tableData.' + scope.$index + '.字段名'" ......
表单 element-ui element table ui

java项目使用Mybatis-Plus插件,QueryWrapper日期开始-结束范围查询

1、参数开始日期startTime、结束日期endTime 挺好用,开始日期、结束日期当天都包含进去了,如果使用qw.between("create_time", startTime, endTime)方法是不含endTime结束日期当天的 qw.apply(bCulresCardMvVO.getS ......

Vue3实战(05)-教你快速搭建Vue3工程化项目

除了Vue 3这个库,还需Vue 3 最新全家桶。 1 环境准备 之前语法演示直接使用script引入Vue 3,从而在浏览器里实现所有调试功能。但实际项目中,使用专门调试工具。在项目上线之前,代码也需打包压缩,并考虑到研发效率和代码可维护性,所以在下面,需建立一个工程化项目实现这些功能。 工具 V ......
Vue3 实战 Vue 项目 工程

vue3.2+ts报错:找不到模块“./App.vue”或其相应的类型声明。

解决方法:在项目根目录创建 env.d.ts 文件(如果已有,则在文件中追加)加入下面内容: declare module '*.vue' { import type { DefineComponent } from 'vue'; const vueComponent: DefineComponen ......
vue 模块 类型 vue3 App

ELement UI 项目中实现多语言(转载)

注意:这里包含了ELementul带组件的多语,跟自定义的(自己创建的en,zh文件,然后调用,然后放上去实现多语)那个不一样,ElementUl的只需要再i18n.is里面调用即可 1.{{$t('Role.roleName')}} 2.$t('Role.roleName') 3.this.$t( ......
ELement 项目 UI

3.web前端开发(Axios,前端工程化,Element,路由)

web前端开发(Axios,前端工程化,Element,路由) Axios Axios官网:https://www.axios-http.cn/ 定义: 引入Axios的js文件; <script src="js.axios-0.18.0.js"></script> 使用Axios发送请求,并获取响 ......
前端 路由 Element 工程 Axios

vue3+vite import 引入ThreeBSP库 报错

我在网上查了一下 先用 npm 下载了三方包 npm i three-js-csg 再使用 const ThreeBSP = require('three-js-csg')(THREE) 的方法引入 出现了这个报错 查了是因为require 是webpack 里的 vite不支持 所以找不到 然后我 ......
ThreeBSP import vue3 vite vue

element 的 el-cascader 控件,去掉空子集

后端返回的树结构数据: template: <el-cascader v-model="ruleForm.columnAll" :options="allColumnData" :props="{ value: 'columnId', label: 'columnName', children: ' ......
空子 控件 el-cascader cascader element

Vue3 + Electron

https://www.electronjs.org/ https://www.electron.build/ 1. 创建一个vue3项目 可参考之前的笔记 2. 安装Electron $ npm install electron -D $ npm install vite-plugin-elect ......
Electron Vue3 Vue

Vue3常用库安装

目录Pinia引入使用Element Plus安装完整引入Volar支持按需导入-自动导入unocss&Icon安装unocss安装Icon库使用动态引用图标Iconify安装使用 Pinia 引入 // main.ts import { createPinia, type PiniaPluginC ......
常用 Vue3 Vue

将Vue3项目部署到Github Pages

1. 创建vue3项目 $ npm init vue@latest 初始化工程,并验证。 2. 创建github仓库 3. 连接vue项目到github仓库 打开vue项目根目录,初始化本地git仓库 $ git init $ git add . $ git commit -m "init" 连接v ......
项目 Github Pages Vue3 Vue

Element X:用 Matrix 2.0 协议打造去中心化 WhatsApp 杀手

导读 Matrix 是一种开源的去中心化通信协议。你可以将其集成到你的服务中,自行托管 Matrix 服务器,或从选定的托管提供商处购买服务器。 Matrix 协议非常适合隐私和安全,并被政府、组织和个人采用。然而,它尚未成功取代 WhatsApp、Telegram 或 iMessage 等中心化消 ......
WhatsApp 杀手 Element Matrix 2.0

Mybatis-Plus--使用p6spy对SQL性能进行监控

第一步、引入maven依赖 <!-- p6spy sql性能分析工具--> <dependency> <groupId>p6spy</groupId> <artifactId>p6spy</artifactId> <version>3.9.1</version> </dependency> 第二步、 ......
Mybatis-Plus 性能 Mybatis p6spy 6spy

mybatis-plus 自定义拦截器

package com.chen.config; import com.baomidou.mybatisplus.annotation.DbType; import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor; ......
mybatis-plus mybatis plus