This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npx react-native bundle | |
--platform ios | |
--dev false | |
--reset-cache | |
--entry-file index.js | |
--bundle-output main.jsbundle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int firstDigit = int.Parse(ssn.Substring(0, 1)); | |
int thirdDigit = int.Parse(ssn.Substring(2, 1)); | |
string type = (firstDigit, thirdDigit) switch | |
{ | |
(8 or 9, _) => "FH", | |
( >= 4 and <= 7, _) => "D", | |
(_, 4 or 5) => "H", | |
_ => null | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int birthYear = (ruleNumber, year) switch | |
{ | |
// Rule 1. 500–749: 1854–1899 | |
(>= 500 and <= 749, >= 54) => 1800 + year, | |
// Rule 2. 000–499: 1900–1999 | |
(< 500, _) => 1900 + year, | |
// Rule 3. 900–999: 1940–1999 | |
(>= 900, >= 40) => 1900 + year, | |
// Rule 4. 500–999: 2000–2039 | |
(>= 500, <= 39) => 2000 + year, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int day = int.Parse(ssn.Substring(0, 2)); | |
int month = int.Parse(ssn.Substring(2, 2)); | |
int year = int.Parse(ssn.Substring(4, 2)); | |
int ruleNumber = int.Parse(ssn.Substring(6, 3)); | |
int birthYear = 0; | |
// Rule 1. 500–749: 1854–1899 | |
if (year >= 54 && ruleNumber >= 500 && ruleNumber <= 749) | |
{ | |
birthYear = 1800 + year; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# just the most essential stuff | |
abbr ga 'git add' | |
abbr gs 'git status' | |
abbr gb 'git branch' | |
abbr gcom 'git commit' | |
abbr gd 'git difftool --no-prompt' | |
abbr gdd 'git difftool --dir-dif' | |
abbr gco 'git checkout' | |
abbr gpr 'git pull --rebase' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*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; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
patch-package | |
--- a/node_modules/@terrylinla/react-native-sketch-canvas/index.js | |
+++ b/node_modules/@terrylinla/react-native-sketch-canvas/index.js | |
@@ -8,6 +8,7 @@ import ReactNative, { | |
ViewPropTypes, | |
} from 'react-native' | |
import SketchCanvas from './src/SketchCanvas' | |
+import resolveAssetSource from "react-native/Libraries/Image/resolveAssetSource" | |
export default class extends React.Component { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"accessibilityComponentType": "String", | |
"accessibilityLabel": "String", | |
"accessibilityLiveRegion": "String", | |
"accessible": "boolean", | |
"alignContent": "String", | |
"alignItems": "String", | |
"alignSelf": "String", | |
"aspectRatio": "number", | |
"backgroundColor": "Color", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"accessibilityLabel": "NSString", | |
"accessibilityTraits": "UIAccessibilityTraits", | |
"accessibilityViewIsModal": "BOOL", | |
"accessible": "BOOL", | |
"alignContent": "YGAlign", | |
"alignItems": "YGAlign", | |
"alignSelf": "YGAlign", | |
"aspectRatio": "float", | |
"backfaceVisibility": "css_backface_visibility_t", |