Skip to content

Instantly share code, notes, and snippets.

🏠
Working from home

Eric Lewis ericlewis

🏠
Working from home
Block or report user

Report or block ericlewis

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ericlewis
ericlewis / CoreDataList.swift
Created Aug 8, 2019
Demonstration of using Core Data with SwiftUI
View CoreDataList.swift
//
// ContentView.swift
// CoreDataSwiftUISample
//
// Created by Eric Lewis on 8/8/19.
// Copyright © 2019 Eric Lewis, Inc. All rights reserved.
//
import SwiftUI
import CoreData
View MusicKittySchema.js
const { gql } = require("apollo-server");
const typeDefs = gql`
type PageInfo {
hasNextPage: Boolean
}
type ArtistEdge {
node: Artist
}
View gist:9aa58eb32d74ce757353f8e79a1ddc61
### Keybase proof
I hereby claim:
* I am ericlewis on github.
* I am ericlewis (https://keybase.io/ericlewis) on keybase.
* I have a public key ASBzIjHMyqm5H8e3230zlAxaBzQMVO1pSYwnw0a_TeEYYgo
To claim this, I am signing this object:
View representable.swift
@propertyWrapper
public struct UserDefault<T>: UserDefaultSpec {
let key: String
let defaultValue: T
public init(_ key: String, defaultValue: T) {
self.key = key
self.defaultValue = defaultValue
}
View CakeView.swift
//
// CircularProgress.swift
// Time!
//
// Created by Eric Lewis on 6/9/19.
// Copyright © 2019 Eric Lewis, Inc. All rights reserved.
//
import SwiftUI
View card.tsx
import React, { useEffect, useRef } from "react";
import {
Animated,
Dimensions,
Image,
StyleSheet,
Text,
TouchableOpacity,
} from "react-native";
import Config from "react-native-config";
View pod.podfile
platform :ios, '12.0'
require_relative '../node_modules/react-native/scripts/autolink-ios'
def common_pods
use_react_native!
end
target 'proj' do
common_pods
View Template.js
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @flow
* @format
*/
@ericlewis
ericlewis / auto-remove-gtk.js
Created May 23, 2019
usage: `node auto-remove-gtk.js pm2-notrack`. the arg is the name of the package you want to publish.
View auto-remove-gtk.js
const assert = require('assert');
assert(process.argv.length > 2, 'Must include a package name');
const newName = process.argv[2];
const util = require('util');
const fs = require('fs');
const exec = util.promisify(require('child_process').exec);
const readFile = util.promisify(fs.readFile);
const writeFile = util.promisify(fs.writeFile);
@ericlewis
ericlewis / auto-remove-gtk.js
Created May 23, 2019
usage: `node auto-remove-gtk.js pm2-notrack`
View auto-remove-gtk.js
const assert = require('assert');
assert(process.argv.length > 2, 'Must include a package name');
const newName = process.argv[2];
const util = require('util');
const fs = require('fs');
const exec = util.promisify(require('child_process').exec);
const readFile = util.promisify(fs.readFile);
const writeFile = util.promisify(fs.writeFile);
You can’t perform that action at this time.