使用
js vue base64文件转file
代码
生成微信小程序码,base64转为file上传到腾讯云cos
/**
* @Author: 858834013@qq.com
* @Name: qrCode
* @Date: 2022-05-17
* @Desc: 生成二维码...
yekong
3年前 (2022-05-17)
喜欢
使用
<uploadFile
:transactTemplateName.sync="scope.row.transactTemplateName"
:transactTemplateP...
yekong
3年前 (2022-05-15)
喜欢
使用实例
<computerIcon :img.sync="ruleForm.imgPath"></computerIcon>
代码
/**
* @Author: 858834013@qq.com
* @Name: Computer...
yekong
3年前 (2022-05-15)
喜欢
vue项目报错
An error occurred in hook getInspectorState registered by plugin org.vuejs.vue2-internal
删除vuex store模块里的namespaced 就不再报错了。
...
yekong
3年前 (2022-05-15)
喜欢
beforeCreate
实例了vue但还没进行数据的初始化与响应式处理
created
数据已被初始化和响应式处理,在这里可以访问到数据,也可以修改数据
beforeMount
render函数在这里被调用,生成点拟DOM,但是还没转成真实DOM并替换到el
mounted
在...
yekong
3年前 (2022-05-15)
喜欢
lazy
作用是,改变输入框的值时:value不会改变,当光标离开输入框时,vmodel绑定的值value
才会改变
trim
作用类似于JavaScript中的trim()方法,作用是把v-model绑定的值的首尾空格给过滤掉。
number
作用是将值转成数字,但是先输关字符...
yekong
3年前 (2022-05-15)
喜欢
在监听函数的时候,我们需要事先请求接口
mounted(){
this.getList()
},
watch: {
searchInput(){
this.getList()
}
}
使用immediate
immediate设置为true的时候,会执行一次...
yekong
3年前 (2022-05-15)
喜欢
vue computed实现传参
// html
<div>{{ totalNum(10) }}</div>
// js
computed: {
totalNum() {
return function(n) {
...
yekong
3年前 (2022-05-15)
喜欢
未使用hook
export default{
data(){
timer:null
},
mounted(){
this.timer = setInterval(()=>{
//具体执行内容
con...
yekong
3年前 (2022-05-15)
喜欢
vue 在keep-alive 使用定时 使用hook的方式结束定时
因为keep-alive 不触发beforeDestroy 所以使用activated
组件使用keep-alive缓存,beforeDestroy和destroyed没有被触发
activated() {
...
yekong
3年前 (2022-05-15)
喜欢