Skip to content

Instantly share code, notes, and snippets.

😀
inducting...

Eric Lewis ericlewis

😀
inducting...
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 / Using mongoDB FTS in Node.js
Created Mar 4, 2013
Hacky way of using mongoDB 2.4RC1's FTS (full text search) in Mongoose w/ node.js
View Using mongoDB FTS in Node.js
Model_to_use.db.db.executeDbCommand({text: "collection_name", search: "term_to_search"}, function(err,response){ ... });
@ericlewis
ericlewis / generate-rncore.js
Created Mar 7, 2019
Generates the files needed for React Native Fabric components.
View generate-rncore.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 / Thing.m
Created Apr 13, 2019
react-native NativeModule for interacting with gmail objc google rest apis
View Thing.m
//
// RNGmailAPI.m
// astroboy
//
// Created by Eric Lewis on 4/9/19.
// Copyright © 2019 Eric Lewis. All rights reserved.
//
#import "RNGmailAPI.h"
#import "RNPromiseWrapper.h"
View RCTNativeTestModuleSpec.h
/**
* RCTNativeTestModuleSpec.h
*
* NOTE: This file is codegenerated.
*/
#import <vector>
#import <Foundation/Foundation.h>
@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);
@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);
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
*/
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 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 CakeView.swift
//
// CircularProgress.swift
// Time!
//
// Created by Eric Lewis on 6/9/19.
// Copyright © 2019 Eric Lewis, Inc. All rights reserved.
//
import SwiftUI
You can’t perform that action at this time.