Skip to content

Instantly share code, notes, and snippets.

Avatar

Jordan Morgan DreamingInBinary

View GitHub Profile
View LInk view
@DreamingInBinary
DreamingInBinary / Best in Class iOS Checklist
Last active Aug 29, 2020
This is a public checklist updated every year after the latest version of iOS and iPadOS are shipped. It's a boiled down version of a "Best in Class" app checklist created by Jordan Morgan.
View Best in Class iOS Checklist
# A Best in Class Checklist
A boiled down checklist adapted from this [post](https://www.swiftjectivec.com/a-best-in-class-app/), created by @jordanmorgan10.
> To use this, create a Github Issue in your own repo, and simply copy and paste this text.
## iOS Core Technology
_Things any iOS app can benefit from_
- [ ] iCloud Sync
- [ ] [Core Spotlight integration](https://github.com/DreamingInBinary/Spend-Stack/issues/120)
View UIView+BFRShimmering.m
//
// UIView+BFRShimmer.h
// BFRUtils
//
// Created by Jordan Morgan on 8/14/18.
// Copyright © 2018 Buffer. All rights reserved.
//
#import <UIKit/UIKit.h>
View gist:e0ddbd81a4fe898efb54f4a0af96729a
sudo cp -r /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/12.0\ \(16A5318d\) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/
@DreamingInBinary
DreamingInBinary / Demo.m
Last active Feb 22, 2018
Machine Learning Blog Post: Snip 3
View Demo.m
#pragma mark - Private Classifiers
- (void)classifyWithModelForImage:(UIImage *)image completion:(void (^)(NSDictionary <NSString *, NSString *> *))completion {
dispatch_async(dispatch_get_global_queue(QOS_CLASS_UTILITY, 0), ^{
NSMutableDictionary *returnValues = [NSMutableDictionary new];
CVPixelBufferRef pixelBuffer = [self generatePixelBufferFromImage:image];
if (pixelBuffer == nil) {
completion(nil);
return;
@DreamingInBinary
DreamingInBinary / Inference.m
Created Feb 22, 2018
Machine Leaning Blog Post: Snip 2
View Inference.m
//
// Inceptionv3.h
//
// This file was automatically generated and should not be edited.
//
#import <Foundation/Foundation.h>
#import <CoreML/CoreML.h>
#include <stdint.h>
@DreamingInBinary
DreamingInBinary / DownloadingAModel.m
Last active Feb 22, 2018
Machine Learning Blog Post: Snip 1
View DownloadingAModel.m
// Once you get the NSData from the download task from where you hosted the file...
#pragma mark - Local Storage
// A 4 Step Process
// 1) Save off the NSData of the Core ML model to a temporary spot
// 2) Compile the model from that URL, whic gives us another temporary URL of where it's compiled at
// 3) Create a permanent URL by appending the temporary URL that was generated. This is what initlizes stuff
// 4) Save the permanent URL for later use
- (void)saveModelData:(NSData *)data {
@DreamingInBinary
DreamingInBinary / ASDisplayNode+BFREmptyView.m
Created Nov 14, 2017
Empty data set for ASDisplayNode
View ASDisplayNode+BFREmptyView.m
//
// ASDisplayNode+BFREmptyView.m
// Buffer
//
// Created by Jordan Morgan on 10/27/17.
//
#import "ASDisplayNode+BFREmptyView.h"
#import <objc/runtime.h>
#import <AsyncDisplayKit/AsyncDisplayKit.h>
View Run iOS 11 devices with Xcode 8
cp -r /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/11.0\ \(15A5278f\) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/
@DreamingInBinary
DreamingInBinary / oldComments.m
Last active Mar 28, 2017
Retrieving old comments in the Buffer Retreat App V1
View oldComments.m
PFQuery *query = [self.event.comments query];
[query includeKey:@"created_by"];
[query orderByAscending:@"createdAt"];
[query findObjectsInBackgroundWithBlock:^(NSArray *objects, NSError *error){
//Handle comments
}];
You can’t perform that action at this time.