Skip to content

Instantly share code, notes, and snippets.

Avatar
😴
☕️⚛️🏃‍♂️🐶

Brent Vatne brentvatne

😴
☕️⚛️🏃‍♂️🐶
View GitHub Profile
View AppDelegate.h
#import <UIKit/UIKit.h>
#import <UMReactNativeAdapter/UMModuleRegistryAdapter.h>
#import <React/RCTBridgeDelegate.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, RCTBridgeDelegate>
@property (nonatomic, strong) UMModuleRegistryAdapter *moduleRegistryAdapter;
@property (nonatomic, strong) UIWindow *window;
@end
View AppDelegate.h
#import <UIKit/UIKit.h>
#import <UMReactNativeAdapter/UMModuleRegistryAdapter.h>
#import <React/RCTBridgeDelegate.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, RCTBridgeDelegate>
@property (nonatomic, strong) UMModuleRegistryAdapter *moduleRegistryAdapter;
@property (nonatomic, strong) UIWindow *window;
@end
View MainApplication.java
package com.myapp;
import android.app.Application;
import com.facebook.react.ReactApplication;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;
import com.facebook.soloader.SoLoader;
View AppDelegate.h
#import <UIKit/UIKit.h>
#import <UMReactNativeAdapter/UMModuleRegistryAdapter.h>
#import <React/RCTBridgeDelegate.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, RCTBridgeDelegate>
@property (nonatomic, strong) UMModuleRegistryAdapter *moduleRegistryAdapter;
@property (nonatomic, strong) UIWindow *window;
@end
View AppDelegate.h
#import <UIKit/UIKit.h>
#import <UMReactNativeAdapter/UMModuleRegistryAdapter.h>
#import <React/RCTBridgeDelegate.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, RCTBridgeDelegate>
@property (nonatomic, strong) UMModuleRegistryAdapter *moduleRegistryAdapter;
@property (nonatomic, strong) UIWindow *window;
@end
@brentvatne
brentvatne / firebase.md
Created Mar 14, 2019
Archiving expo-firebase
View firebase.md

We started building expo-firebase based off of react-native-firebase in order to attempt to get it to work well within the Expo client. It turned out that there wasn't a good way to do this - the SDK fully expects that there is one binary per app, and the Expo client has multiple apps inside of it. We weren't able to work around this.

If you'd like to use Firebase in the Expo client with the managed workflow, we'd recommend using the Firebase JS SDK. It supports Firebase Realtime Database and Firebase Storage. If you'd like access to the full suite of native firebase tools, we recommend using the bare workflow and react-native-firebase, because we cannot support this in the Expo client currently.

View hello.md

👋👋👋👋👋👋👋👋👋👋👋👋👋👋👋👋👋

@brentvatne
brentvatne / gist:24cf4387fa8751c136d388e6211400a7
Created Nov 13, 2018
Learn more about Fiber, Fabric, and JSI
View gist:24cf4387fa8751c136d388e6211400a7
- A cartoon intro to Fiber - https://www.youtube.com/watch?v=ZCuYPiUIONs
- State of React Native 2018 - http://facebook.github.io/react-native/blog/2018/06/14/state-of-react-native-2018
- Fabric Proposal - https://github.com/react-native-community/discussions-and-proposals/issues/4
- View flattening with Fabric - https://cl.ly/950e8fb4da6d
- An informal talk about Fabric at Facebook - https://www.facebook.com/hramos/videos/10101317533036249/
- React Native's New Architecture - https://www.youtube.com/watch?v=UcqRXTriUVI
View Podfile
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'
target 'YOUR_PROJECT_NAME' do
pod 'ExpoKit',
:git => "http://github.com/expo/expo.git",
:tag => "ios/2.7.0",
:subspecs => [
"Core"
],
View portal.js
// This example is a little bit contrived because we have more
// control over this situation, but basically I want to know if
// it's possible to render contents parent's siblings and preserve
// context of the original render site, without using any native
// code (eg: the Modal component in React Native)
import React from 'react';
import { Text, View } from 'react-native';
import { PortalHost, Portal } from 'my-imaginary-library';