- 博客(300)
- 资源 (9)
- 收藏
- 关注
原创 apple-app-site-association nginx
3. 上传apple-app-site-association到applinks中填写的https服务器根目录或者.well-known目录下。2. 创建 apple-app-site-association 文件,无json等后缀名。eg: appID 构成 teamId + bundleId。4. 重新安装app,然后就可以测试。
2023-10-25 18:00:36
4508
原创 react-navigation之navigate
react-navigation之navigatenavigate用于页面之间的跳转,eg : navigation.navigate("routeName", {postText:"ddd"});参数1 跳转页面参数2 传递的参数 paramsreact-navigation官方推荐 params要尽可能的简单化,简单的key、value。避免添加callback函数或者数据对象,但是避免不了页面返回的时候需要回调的问题,这时候官方推荐了坚决方案。还是通过 navigate,eg:
2021-09-24 17:09:54
4378
原创 iOS Podfile修改优化
post_install do |installer| installer.pods_project.targets.each do |target| if (target.name&.eql?('FBReactNativeSpec')) target.build_phases.each do |build_phase| if (build_phase.respond_to?(:name) && build_phase.n...
2021-08-11 14:02:51
903
原创 error: Cycle in dependencies between targets ‘FBReactNativeSpec‘
error: Cycle in dependencies between targets ‘FBReactNativeSpec’处理方法Click on the Pods project on the left sidebarGo under Build PhasesMake sure [CP-User] Generate Specs is before Headershttps://github.com/facebook/react-native/issues/31034...
2021-08-10 14:31:21
1925
原创 Undefined symbols for architecture arm64: “Swift._ArrayBuffer._copyContents...“
运行环境 macOSnode v14 run-android$ react-native run-androidinfo Running jetifier to migrate libraries to AndroidX. You can disable it using "--no-jetifier" flag.Jetifier found 1358 file(s) to forward-jetify. Using 4 workers...info JS server already run
2021-06-25 17:07:47
366
原创 react-native EventEmitter 移除了once()方法记录
EventEmitter: Delete once() and removeCurrentListener() …Summary:In an effort to simplify and clean up the EventEmitter abstractions in React Native, this removes once() and removeCurrentListener(). Across the Facebook codebase, there were only two calle
2021-06-23 15:30:36
497
原创 react-native webview同h5、vue页面交互记录
h5 或者vue添加监听 /* * vue 监听采用 * window.window.addEventListener ios * window.document.addEventListener android * h5 * window.addEventListener ios * document.addEventListener android * */// 具体是用window还是document如上面描述win...
2021-05-25 15:13:40
641
1
原创 Double-quoted include “YGMacros.h“ in framework header, expected angle-brack
Double-quoted include “YGMacros.h” in framework header, expected angle-brack解决方案找到pods, 打开 buildsettings搜索quoted include,设置 该属性为No
2020-10-22 16:12:31
6212
1
原创 数字转字符串输出固定位数,不足补0
数字转字符串输出固定位数,不足补0实力如下: static PrefixInteger(num, length) { return (Array(length).join('0') + num).slice(-length); }
2020-01-03 09:49:18
2039
转载 Could not connect to lockdownd. Exiting
执行命令ideviceinstaller -l报错:Could not connect to lockdownd. Exiting.尝试以下命令重新编译库1 brew uninstall -f libimobiledevice ideviceinstaller usbmuxd 如果失败执行: brew uninstall --ignore-dependencies lib...
2019-04-09 10:48:29
3122
原创 mac 下 intall fbsimctl问题及过程
brew tap facebook/fb and brew install fbsimctl --HEAD失败后cd /Users/admin/Library/Caches/Homebrew/fbsimctl./build.sh fbsimctl build /usr/local/Cellar/fbsimctl/HEAD-9911af8上面路径换成自己的,等待下载编译完成...
2019-01-16 22:31:11
1566
原创 'config.h' file not found 问题处理方法
react-native 项目在编译的时候,突然报错 ‘config.h’ file not found mutex.h处理方法很简单,以此执行以下命令:cd node_modules/react-native/third-party/glog-0.3.4../../scripts/ios-configure-glog.sh...
2018-12-04 10:08:50
5120
原创 XCode升级10版本遇到的link问题
Xcode升级到最新版本10,有些旧的项目运行出报错,如 link error,具体如下:error:Build input file cannot be found:‘/Users/…/Libraries/WebSocket/libfishhook.a’这是我的一个react-native 项目在进行XCode上进行编译的时候所报的错误,libfishhook 链接错误,找不到文件了,解决的...
2018-10-23 10:48:42
1450
转载 flutter 安装配置
Flutter 初尝:从 Java 无缝过渡准备阶段 下载 Flutter SDK新建 Flutter 文件夹,克隆 Flutter SDK:git clone -b beta https://github.com/flutter/flutter.git 配置 Flutter 环境我是 Mac 系统,Flutter SDK 下载完后的路径:Users/yourusername/...
2018-07-06 14:05:03
356
原创 js 动态替换字符串
环境:被替换字符串及替换字符串都是由外面传进来,需要替换满足条件的所有字符串。 例子: var str = “(&[DT])?Utils.strToDate(&[DT])”;需要将str 转换为 “(getValue(DT))?Utils.strToDate(getValue(DT))”;var key = ‘DT’; var result = str.replac...
2018-03-05 15:53:46
1776
原创 Cocoapods的更新及其过程
今天使用pod 更新第三方库的时候,突然报错了,查询后发现是由于 cocoapods 版本太低导致的更新失败,于是乎,开始更新cocoapads,然而更新cocoapods也失败了,报错SSL_connect returned=1 errno=0 state=SSLv2/v3 read server hello A: sslv3 alert handshake failure (https://ge
2017-11-27 19:30:21
514
原创 react-native之Realm数据库的使用(一)
realm数据库是一款小型数据库系统,可以支持多个平台,如android、ios、javascript等。当然了realm也是可以支持react-native的,官网有具体介绍,官网文档安装realmnpm install --save realm然后linkreact-native link realm或者rnpm link realm如果link不完全,可以手动检查添加1.Add the fol
2017-11-09 16:19:41
3781
原创 iOS11及XCode升级后的问题收集
报错的样式变了,如果他可以fix的,会提示详细的fix的代码xib的约束条件变了,需要适当修改iPhone X的适配,上下边距问题处理支持了无线调试UITableView 设置区头跟区尾的代理方法,要写这个代码才能生效,否则设置无效self.tableView.sectionHeaderHeight=self.tableView.sectionFooterHeight=对于布局table
2017-09-29 08:37:53
700
原创 react-native 下编写工具、Public类
在react-native开发中,一些常用到的方法函数,我们可以提取出来写到一个公共的类里面,方便不同页面的调用。 首先、新建一个文件 PublicUtils.js 里面实现如下:let PublicUtils = { GUID: ()=> { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, f
2017-08-19 09:00:38
625
原创 PhotosUI 取图片为nil问题
原先通过一下代码取图片很正常,使用的PhotosUI框架 [self.imageManager requestImageDataForAsset:asset options:PHImageRequestOptionsResizeModeNone resultHandler:^(NSData* imageData, NSString* dataUTI, UIImageOrientation or
2017-07-25 10:34:30
1221
原创 react-native之Image加载url图片问题
react-native之Image加载图片问题Image加载图片有两种方式,一种是本地资源,一种可以是网络图片,本地资源加载,如:<Image source={require('./images/add.png')}/>这种方式简单,都没有问题。通过url的方式加载图片,如: <Image source={{uri:'http://xxxxxxxx'}} style={{width: 90,
2017-07-06 10:29:37
18448
1
原创 react-native 之 ref 的使用
在react-native中可以通过 ref属性来获取组件,并设置组件的属性及其方法,实例如下class TestRef extends Component { // 构造 constructor(props) { super(props); // 初始状态 this.state = {}; this.changeSty
2017-06-29 16:50:00
5412
原创 iOS 加载本地html、js、css方法
如何加载已经写好的静态页面呢?可以通过下面几个步骤解决: 1、将文件拷贝到项目中 2、将其拉入项目,注意选择Create folder references 然后可以看到在项目中,其显示的为蓝色文件夹 3、打开assets目录下html页面 NSString *path = [[NSBundle mainBundle] pathForResource:@"html_doc" o
2017-06-21 10:16:42
4955
原创 关于JaveScriptCore框架使用注册方法
关于JaveScriptCore框架使用注册方法 在大概去年的时候,iOS SDK开放了JaveScriptCore框架的一些API,这使得本地同JS的交互更加便捷了,我们可以直接本地注册方法,webView上的js就可以调用我们写的操作了,相对以前的通过地址栏拦截的操作方便多了,但是这同样有一个问题需要注意:在实际操作中,我们第一次注册完了方法,当网页发生跳转,有页面A跳到页面B的时候,B页面就
2017-06-13 09:18:44
485
原创 iOS10 新的通知框架 UserNotifications
iOS10采用了新的通知框架,相比较原来的框架,功能丰富了不少,在使用前需引入框架@import UserNotifications;使用前需要用户授权 if ([[UIDevice currentDevice].systemVersion floatValue] >= 10.0) { UNUserNotificationCenter *center = [UNUserNoti
2017-06-13 09:11:03
465
原创 html中使用iconfont
可以通过网站 iconfont 选择并下载需要的图标, 解压后如下: 将其放入项目中,然后设置如下,注意路径设置 <style type="text/css"> @font-face { font-family: "iconfont"; src: url('AmazeUI-2.7.2/fonts/iconfont.eot'
2017-06-02 11:53:40
3406
原创 iOS实现RTMP视频直播 IJKMediaFramework框架编译
通过xcode checkouthttps://github.com/Bilibili/ijkplayer.git或者在终端输入命令git clone https://github.com/Bilibili/ijkplayer.git在将整个工程包克隆到本地后,打开其文件夹 ijkplayereg:cd ijkplayer-ios运行iOS初始化脚本./init-ios.sh完成依赖库下载之后,执行
2017-05-11 16:23:43
1777
原创 react-native之flex布局总结
flex布局之横纵布局 <View style={{flex: 1, flexDirection: 'row'}}> <View style={{width: 50, height: 50, backgroundColor: 'powderblue'}} /> <View style={{width: 50, height: 50, backgroundC
2017-04-22 10:21:57
696
原创 OpenGL ES资源收集
GLSL教程篇 http://blog.youkuaiyun.com/racehorse/article/details/6593719OpenGL ES教程篇教程1,来自 cnblog http://www.cnblogs.com/kesalin/archive/2012/11/24/opengl_es_tutorial_01.html 教程2,来自 简书 http://www.jianshu.com
2017-03-28 11:30:47
465
原创 微信小程序之页面跳转错误
微信小程序在进行页面切换的时候,页面路径对于新手来说,很容易造成莫名其妙错误,比如:WAService.js:1 navigateTo:fail url not in app.json而查看app.json的时候,是正常的,页面写进入了app.json. 那么就只能是url的问题了, 先看一下目录: 这时候写的跳转url为,当前页面为login,由login 页面跳转mailList页面 u
2017-02-25 11:19:38
17026
原创 高精度的定时器:dispatch_source_t
NSTimer受runloop的影响,由于runloop需要处理很多任务,导致NSTimer的精度降低,在日常开发中,如果我们需要对定时器的精度要求很高的话,可以考虑 dispatch_source_t 去实现 。dispatch_source_t 精度很高,系统自动触发,系统级别的源。下面是通过dispatch_source_t 创建 计时器的例子 dispatch_queue_t queu
2017-02-14 16:26:24
1737
转载 OC与JS交互之JavaScriptCore
转载自:http://www.cnblogs.com/markstray/p/5757255.htmlJavaScriptCore提供了JavaScript和Objective-C桥接的Obj-C API。JavaScriptCore提供了让我们脱离UIWebView执行JavaScript脚本的能力,以及使用现代的Objective-C语法(例如Blocks和下标)在Objective-C和Jav
2017-02-10 11:15:59
773
原创 iOS 位置权限弹出框闪现问题
当编码如下的时候,进入页面的时候可以看到UIAlertView弹出框出现一下,刚想点击的时候,他不见了,这个郁闷 CLLocationManager* _locationManager = [[CLLocationManager alloc] init]; _locationManager.desiredAccuracy = kCLLocationAccuracyHundredMete
2017-02-09 16:39:13
4741
原创 UIScrollView 的滑动研究
有时候我们需要根据UIScrollView的滑动位置来做出相应的操作,比如很多日历中都有 month 日历同 week日历的切换,通过UIScrollView可以实现这样的效果,这时候通过判断手离开视图的那个瞬间就需要做出判断了,如果在手指离开屏幕的时候,UIScrollView没有在滑动,那么这时候就可以通过方法- (void)scrollViewDidEndDragging:(UIScrollV
2017-01-16 15:08:11
682
转载 详细分享UICollectionView的自定义布局(瀑布流, 线性, 圆形...)
转载自:http://www.jianshu.com/p/cabec2786241 前言:本篇文章不是分享collectionView的详细使用教程, 而是属于比较’高级’的collectionView使用技巧, 阅读之前, 我想你已经很熟悉collectionView的基本使用, 如果不是很熟悉, 建议在以后熟悉一下. 那么在本篇结束后, 你也能够很轻松的使用collectionView来实现,
2017-01-16 09:34:14
365
转载 Runtime常用的几个应用场景
转载自:http://www.jianshu.com/p/cafbddab31dd 概述 接上篇《Runtime基本原理及Demo》,了解了Runtime相关基础知识后,我们谈一下Runtime常见的几个应用场景。Runtime常见应用场景 具体应用拦截系统自带的方法调用(Method Swizzling黑魔法) 实现给分类增加属性 实现字典的模型和自动转换 JSPatch替换已有的OC
2016-12-26 15:29:06
566
原创 iOS扩展开发攻略
什么是扩展? 扩展( Extension )是 iOS 8 中引入的一个非常重要的新特性。扩展让 app 之间的数据交互成为可能。用户可以在 app 中使用其他应用提供的功能,而无需离开当前的应用。在 iOS 8 系统之前,每一个 app 在物理上都是彼此独立的, app 之间不能互访彼此的私有数据。而在引入扩展之后,其他 app 可以与扩展进行数据交换。基于安全和性能的考虑,每一个扩展运行在一个
2016-12-22 14:13:43
425
原创 通过UIActivityViewController分享内容
NSString *textToShare = @"分享内容标题"; UIImage *imageToShare = [UIImage imageNamed:@"icon.png"]; NSURL *urlToShare = [NSURL URLWithString:@"分享内容地址]; NSArray *activityItems = @[urlTo
2016-12-20 15:10:20
1812
转载 iOS平台基于ffmpeg的视频直播技术揭秘
转载自:http://www.jianshu.com/p/6b56f9ef3b95 现在非常流行直播,相信很多人都跟我一样十分好奇这个技术是如何实现的,正好最近在做一个ffmpeg的项目,发现这个工具很容易就可以做直播,下面来给大家分享下技术要点:首先你得编译出ffmpeg运行所需的静态库,这个百度一下有很多内容,这里我就不多说了,建议可以用Github上的一个开源脚本来编译,简单粗暴有效率。地址
2016-12-19 15:25:58
591
teleport-assist-macos-3.5.5.dmg
2021-03-18
Genymotion 2.5.4 reg.exe 文件
2015-10-13
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人