Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯

JM Myers jm90m

🎯
  • Burlington, MA
View GitHub Profile
@jm90m
jm90m / gu-deck-encoder
Created Sep 10, 2019
incomplete implementation of deck decoder
View gu-deck-encoder
const GOD_NAMES = {
nature: 1,
war: 2,
death: 3,
light: 4,
magic: 5,
deception: 6,
};
function collectCards(cards) {
View .babelrc
{
"presets": ["babel-preset-expo"],
"env": {
"development": {
"plugins": [
"transform-react-jsx-source",
[
"module-resolver",
{
"root": ["./src"]
View circle with line
import styled from 'styled-components/native';
const Circle = styled.View`
width: 50px;
height: 50px;
border-radius: 25px;
background-color: blue;
`;
const Line = styled.View`
View gist:91b4f6d429f770648253c3f05cfcba82
window.__PRELOADED_STATE__ = {"app":{"isFetching":false,"isLoaded":true,"rate":0,"trendingTopicsLoading":false,"trendingTopics":[],"rewardFund":{},"bannerClosed":false,"appUrl":"http://localhost:3000","usedLocale":"en","cryptosPriceHistory":{},"showPostModal":false,"currentShownPost":{}},"auth":{"isAuthenticated":true,"isFetching":false,"isReloading":false,"loaded":true,"user":{"id":395827,"name":"jm90mm","owner":{"weight_threshold":1,"account_auths":[],"key_auths":[["STM82TbviXvUFjewgPuNMH5KZESuuEvCN7rUEq5YNZBMYninpdDk2",1]]},"active":{"weight_threshold":1,"account_auths":[],"key_auths":[["STM8MTKnN8RtgVSXYkXXVW7oV8UYtPDuZohDAbtXo25xfWsV16J8M",1]]},"posting":{"weight_threshold":1,"account_auths":[["busy-mobile",1],["busy.app",1],["utopian.app",1]],"key_auths":[["STM8F8CGW67Vf6kbrcZQHtsJ7obQ1UL84WycnScrLF9s1B4JiV7Xn",1]]},"memo_key":"STM8UQhYmVF9eJMDcKjKPkjEMNrJjUEGVeswGvdnNcuaxrmdF1nBM","json_metadata":"{\"profile\":{\"name\":\"JM Myers\",\"profile_image\":\"https://avatars2.githubusercontent.com/u/5067716?s
View UserBlog
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { RefreshControl, ListView } from 'react-native';
import _ from 'lodash';
import styled from 'styled-components/native';
import { COLORS } from 'constants/styles';
import PostPreview from 'components/post-preview/PostPreview';
import UserHeader from 'components/user/user-header/UserHeader';
const StyledListView = styled.ListView`
@jm90m
jm90m / App.js
Created Jul 30, 2017
expo-netflix-example
View App.js
import React from 'react';
import { StatusBar } from 'react-native';
import { DrawerNavigator, DrawerItems } from 'react-navigation';
import HomeStackNavigator from 'components/navigation/home-stack-navigator';
import { COLORS } from 'constants/styles';
import styled from 'styled-components/native';
const DrawerContainer = styled.View`
flex: 1;
background-color: ${COLORS.GREY.BRIGHT_GREY};
@jm90m
jm90m / home-stack-navigator.js
Created Jul 30, 2017
expo-netflix-example home-stack-navigator
View home-stack-navigator.js
import React from 'react';
import { StackNavigator } from 'react-navigation';
import HomeScreen from 'components/screens/home-screen';
import ShowDetailsScreen from 'components/screens/show-details-screen';
const HomeStackNavigator = StackNavigator(
{
Main: { screen: HomeScreen },
ShowDetails: { screen: ShowDetailsScreen },
},
@jm90m
jm90m / home-screen.js
Created Jul 30, 2017
expo-netflix-example home-screen
View home-screen.js
import React, { Component } from 'react';
import styled from 'styled-components/native';
import Header from 'components/common/header';
import { COLORS } from 'constants/styles';
import { TouchableWithoutFeedback, ScrollView, TouchableOpacity } from 'react-native';
import ShowData from 'data/data';
import Icon from 'react-native-vector-icons/FontAwesome';
const Container = styled.View`
display: flex;
@jm90m
jm90m / show-details-screen.js
Created Jul 30, 2017
expo-netflix-example show-details-screen
View show-details-screen.js
import React, { Component } from 'react';
import { TouchableOpacity } from 'react-native';
import styled from 'styled-components/native';
import { COLORS } from 'constants/styles';
import Icon from 'react-native-vector-icons/FontAwesome';
const Container = styled.View`
background-color: ${COLORS.GREY.BLACK_RUSSIAN};
height: 100%;
`;
@jm90m
jm90m / header.js
Created Jul 30, 2017
expo-netflix-example header component
View header.js
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import styled from 'styled-components/native';
import Icon from 'react-native-vector-icons/FontAwesome';
import { COLORS } from 'constants/styles';
import { TouchableWithoutFeedback } from 'react-native';
const NETFLIX_LOGO = require('../../../assets/icons/netflix-logo.png');
const Container = styled.View`
display: flex;