- 博客(10)
- 资源 (3)
- 收藏
- 关注
原创 vue3 <script setup> 子组件,获取父组件的数据
vue3 <script setup> 中 子组件,获取父组件的数据父组件<template> <div> <slot/> </div></template><script lang="ts" setup>const props = defineProps({ type: { type: String, default: 10 }})</s
2021-07-13 16:20:24
5734
原创 vue3 <script setup> 自定义组件中,判断 slot 是否有内容。
vue script setup 自定义组件中,判断 slot 是否有内容。<template> <div> <slot/> <slot name="test"/> </div></template><script lang="ts" setup>import { useSlots } from "vue";//判断<slot/>是否有传值const slotDe
2021-07-13 16:15:03
10703
原创 vue3 <script setup> 执行子组件里的方法函数
vue3 script setup 执行子组件里的方法函数在搞自定义组件开发的时候,遇到的问题,vue2时,子组件里的方法函数,可以直接通过 this.$refs.xxx.xxxx() 来执行,但在vue3中,尤其是 <script setup> 中,是不允许这样的,由于 <script setup> 目前没啥文档,相关资料,不太好找,最后再github反馈,才找到解决方案,这个方案,很简单,实际上,就是vue2的思维,没转换过来。自定义组件<template>
2021-07-13 15:58:37
6393
4
原创 ColorUI 微信小程序 商品详情页模板,仿微信胶囊
使用的是colorui的小程序UI框架。colorui地址:https://www.color-ui.com/index.wxml<!--商品轮播图--><swiper class="screen-swiper square-dot bg-white" indicator-dots="true" circular="true" autopla...
2019-03-18 23:24:26
9890
3
原创 微信小程序,Promise异步请求个人觉得最舒服的方式
app.jsPromise: function(promise){ let APIURL = 'https://xxx.xxxx.com/'; return new Promise(function (resolve, reject){ wx.request({ url: APIURL + promise...
2019-03-15 12:02:35
4337
原创 微信小程序 colorui 修改弹出加载框的问题(2.0.2版本)
使用的是colorui的小程序UI框架。colorui地址:https://www.color-ui.com/wxml代码<view class="canui-load" wx:if="{{loadModal}}"> <view class='cu-load load-modal text-blue' wx:if="{{loadModal}}"&g...
2019-03-08 11:27:16
3515
原创 微信小程序 colorui购物车界面模板(无功能)
使用的是colorui的小程序UI框架。colorui地址:https://www.color-ui.com/index.wxml<view class="cu-custom" style="height:{{CustomBar}}px;"> <view class="cu-bar fixed none-bg text-white ...
2019-03-08 00:17:13
7346
原创 微信小程序 colorui 仿美团优选商家模板界面(无功能)
使用的是colorui的小程序UI框架。colorui地址:https://www.color-ui.com/index.wxml<!--状态栏区域--><view class="cu-custom" style="height:{{CustomBar}}px;"> <view class="cu-bar fixed none-bg ...
2019-03-08 00:14:06
7494
3
原创 ThinkPHP5.0 修改配置文件函数。
TP5 修改配置文件函数/** * 修改配置文件 * @param string $file 配置文件名(不需要后辍) * @param array $data 需要更新或添加的配置 * @return bool */function setconfig($file,$data){ if (is_array($data)){ $fileurl = APP...
2018-12-21 16:44:57
850
1
转载 Laravel和ThinkPHP个人常用自定义函数库
1. 字符串转换为数组(主要用于把分隔符调整到第二个参数)/** * [os_Str2arr 字符串转换为数组] * 主要用于把分隔符调整到第二个参数 * @param [type] $str [要分割的字符串] * @param string $glue [分割符] * @return [type] [description] */function os_S...
2018-10-09 15:44:18
396
1
Sublime Text 3编辑器用的T5语法提示插件
2018-12-22
易语言5.71破解版(免狗、可静态编译)
2018-05-06
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人