摘要: console.log([ " _ooOoo_", " o8888888o", " 88\" . \"88", " (| -_- |)", " O\\ = /O", " ____/` '\\____", " .' \\\\| |// `.", " / \\\\||| : |||// \\", " / 阅读全文
posted @ 2021-11-04 08:45 Y-X南川 阅读(457) 评论(0) 推荐(0) 编辑
摘要: 公众号H5页面接入微信登录流程 源码地址 https://gitee.com/szxio/h5_weixin 起步 首先创建一个项目,我们采用uni-app来作为我们的前端框架 环境安装 全局安装vue-cli npm install -g @vue/cli 创建uni-app 使用正式版(对应HB 阅读全文
posted @ 2021-10-29 15:52 Y-X南川 阅读(3991) 评论(0) 推荐(0) 编辑
摘要: <html style="height: 100%"> <head> <meta charset="utf-8"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width,initial-scale=1.0,m 阅读全文
posted @ 2021-09-26 09:47 Y-X南川 阅读(7941) 评论(0) 推荐(0) 编辑
摘要: 源码地址 点击查看演示源码 Vue2父子传参:props 首先在父组件中引入子组件,然后以属性的方式将数据传递给子组件 父组件: <template> <div class="home"> <!-- 在子组件中使用 :变量名=value 的方式向子组件传递数据,子组件通过 props 接收--> < 阅读全文
posted @ 2021-08-10 15:13 Y-X南川 阅读(3582) 评论(0) 推荐(0) 编辑
摘要: 使用 localeCompare() 方法来进行字符串排序 let str = "qwertyuasdfghjzxcvbn"; str = [...str].sort((a,b)=>{ return a.localeCompare(b,"zh-CN") }).join("") console.log 阅读全文
posted @ 2021-08-03 13:33 Y-X南川 阅读(1096) 评论(0) 推荐(0) 编辑
摘要: @Test public void show(){ String s1 = "qwertyasdfghzxcvbn"; String s2 = myStrSort(s1); System.out.println(s2); //=> abcdefghnqrstvwxyz } public String 阅读全文
posted @ 2021-08-03 13:30 Y-X南川 阅读(1053) 评论(0) 推荐(0) 编辑
摘要: @Test public void testGetSomeStr() { String a = "sffioafihellosdfvasdf"; String b = "sfhellodesdfs"; String c = getSomeStr(a, b); System.out.println(c 阅读全文
posted @ 2021-08-03 13:29 Y-X南川 阅读(430) 评论(0) 推荐(0) 编辑
摘要: 方式一:使用 replace 的方式计算字符串出现次数 @Test public void show() { String s1 = "absfsdfabsdfosfabsfspfoj"; String s2 = "ab"; // 获取原始字符串的长度 int oldCount = s1.lengt 阅读全文
posted @ 2021-08-03 13:28 Y-X南川 阅读(10112) 评论(0) 推荐(1) 编辑
摘要: 方式一 @Test public void show() { String s1 = "abcdefg"; String s2 = "a"; // 先将需要翻转的字符串给截取出来 char[] chars = s1.substring(1, 6).toCharArray(); // 循环截取出来的字 阅读全文
posted @ 2021-08-03 13:26 Y-X南川 阅读(316) 评论(0) 推荐(0) 编辑
摘要: public class StringDemo1 { @Test public void show() { String s1 = " hello world sss "; String s2 = myTrim(s1); System.out.println(s2); //=> hello worl 阅读全文
posted @ 2021-08-03 13:22 Y-X南川 阅读(523) 评论(0) 推荐(0) 编辑