随笔分类 -  Uniapp

Uniapp
摘要:直接上代码 // #ifdef H5 var app_type = this.isWeiXin() ? 'wechat' : 'h5'; var app_type_name = this.isWeiXin() ? '微信公众号' : 'H5'; // #endif // #ifdef MP-WEIX 阅读全文
posted @ 2023-12-26 17:24 79524795 阅读(403) 评论(0) 推荐(0) 编辑
摘要:Uniapp中弹窗 直接上代码 uni.showModal({ title: '提示', content: '这是一个自定义按钮文字的模态对话框', confirmText: '自定义确定', // 自定义确定按钮的文字 cancelText: '自定义取消', // 自定义取消按钮的文字 succ 阅读全文
posted @ 2023-10-27 18:16 79524795 阅读(133) 评论(0) 推荐(0) 编辑
摘要:直接上代码 // display: flex; // flex-direction: column; // align-items: center; // justify-content: center; 阅读全文
posted @ 2023-04-26 11:51 79524795 阅读(343) 评论(0) 推荐(0) 编辑
摘要:直接上代码 .img1a{ position: relative; width: 100%; height: 100%; } .video-open{ margin-left: 45%; margin-top: 45%; position: absolute; z-index: 9999; widt 阅读全文
posted @ 2023-04-01 16:21 79524795 阅读(190) 评论(0) 推荐(0) 编辑
摘要:安装 npm install hls.js -S 代码 <template> <view class="vid"> <view class="navv"> <u-navbar autoBack leftText="返回" :title="title" height="88rpx"> </u-navb 阅读全文
posted @ 2023-01-19 00:22 79524795 阅读(251) 评论(0) 推荐(0) 编辑
摘要:Uniapp提交表单 <form> <uni-view data-v-13695da5="" data-v-96bbcaca="" class="forecastContainer"> <uni-scroll-view data-v-13695da5="" class="scroll-view" s 阅读全文
posted @ 2023-01-19 00:17 79524795 阅读(143) 评论(0) 推荐(0) 编辑
摘要:1. uni.navigateTo 用于跳转到非 tabbar 页面,保留当前页面,允许返回。 methods:{ toDeposit () { uni.navigateTo({url:'/pages/me/duihuan'}) }, } 2. uni.redirectTo 用于跳转到非 tabba 阅读全文
posted @ 2023-01-14 11:42 79524795 阅读(88) 评论(0) 推荐(0) 编辑
摘要:一句代码 location.reload() 阅读全文
posted @ 2023-01-14 11:40 79524795 阅读(13) 评论(0) 推荐(0) 编辑
摘要:如果是true运行问好后面的,如果false运行‘’ <view class="recharge_head_li center" :class="totalIn>0 && totalIn<30 ? 'chs':''" @click="" v-for="" :key=""> <text>0-30</t 阅读全文
posted @ 2023-01-14 11:38 79524795 阅读(980) 评论(0) 推荐(0) 编辑
摘要:我是前端小白萌新一枚 最近在用uniapp写一个app 遇到不少坑 特此记录一下啦~~一开始我存储数据时用vue中的store 在登陆的时候把获取到的个人信息存储在store的仓库里面,然后在每个页面需要的地方获取数据 例如获取用户id 1.store /index.js import Vue fr 阅读全文
posted @ 2023-01-08 09:59 79524795 阅读(1826) 评论(0) 推荐(0) 编辑
摘要:uniapp代码 <view> <text style="margin-left: 40rpx;" class="all-tx color-base-text" @click="uploadskm">上传图</text> <view> <img @click="uploadskm" style="w 阅读全文
posted @ 2022-07-26 10:44 79524795 阅读(662) 评论(0) 推荐(0) 编辑
摘要:var url = window.location.search; var theRequest = new Object(); if (url.indexOf("?") != -1) { var str = url.substr(1); var strs = str.split("&"); for 阅读全文
posted @ 2022-07-23 10:14 79524795 阅读(7673) 评论(0) 推荐(0) 编辑
摘要:window.location.href = 'https://mp.weixin.qq.com/'; 阅读全文
posted @ 2022-07-12 15:06 79524795 阅读(738) 评论(0) 推荐(0) 编辑
摘要:案例 <navigator url="/pages/index1/index1" hover-class="navigator-hover"> <button type="default">跳转到新页面</button> </navigator> 阅读全文
posted @ 2022-07-12 14:13 79524795 阅读(326) 评论(0) 推荐(0) 编辑
摘要:1,直接弹窗 uni.showToast({ title: '标题', duration: 2000 }); 2,隐形弹窗 隐藏提示框:uni.hideToast(); 3,选择框 之 弹窗双选择 uni.showModal({ title: '提示', content: '这是一个模态弹窗', s 阅读全文
posted @ 2022-07-06 18:40 79524795 阅读(902) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示