Skip to content

Instantly share code, notes, and snippets.

View cbrevik's full-sized avatar
🙈

Christian Brevik cbrevik

🙈
View GitHub Profile
{
"accessibilityComponentType": "String",
"accessibilityLabel": "String",
"accessibilityLiveRegion": "String",
"alignContent": "String",
"alignItems": "String",
"alignSelf": "String",
"allowFontScaling": "boolean",
"aspectRatio": "number",
"autoCapitalize": "number",
@cbrevik
cbrevik / error-report.js
Created January 31, 2017 07:40 — forked from tianjianchn/error-report.js
Error report util with fabric/crashlytics in react-native
/*global __DEV__*/
import StackTrace from 'stacktrace-js';
const Fabric = require('react-native-fabric');
const { Crashlytics } = Fabric;
//call this to start capturing any no-handled errors
exports.init = function(captrueOnDebugMode){
if (__DEV__ && !captrueOnDebugMode) {
return;
@cbrevik
cbrevik / stupid.js
Last active December 1, 2016 13:37
Uten noe jukse string-splitting
function f(s) {return Math.floor((s*4) / Math.pow(10, Math.floor(Math.log10(s*4)))) == 6 ? s : f(((s*4) % Math.pow(10, Math.floor(Math.log10(s*4)))) * 10 + 6)}
let rec stupid s =
if (int) (floor ((float) (s * 4) / (float) (pown 10 ((int) (floor (log10 ((float) (s * 4)))))))) = 6
then s
else stupid (((s * 4) % (pown 10 ((int) (floor (log10 ((float) (s * 4))))) )) * 10 + 6)
stupid 6

Keybase proof

I hereby claim:

  • I am cbrevik on github.
  • I am cbrevik (https://keybase.io/cbrevik) on keybase.
  • I have a public key whose fingerprint is BF7A 3877 E4D7 72C6 97EE 7811 9ED8 8DB7 5E25 0456

To claim this, I am signing this object: