Skip to content

Instantly share code, notes, and snippets.

View kevinnguy's full-sized avatar
🤓
Code reviewing!

Kevin Nguy kevinnguy

🤓
Code reviewing!
View GitHub Profile
@kevinnguy
kevinnguy / @apollo+client+3.3.11.patch
Created March 6, 2021 06:09
@apollo/client patch for RN live reloading
diff --git a/node_modules/@apollo/client/apollo-client.cjs.js b/node_modules/@apollo/client/apollo-client.cjs.js
index f04faf8..9be6c37 100644
--- a/node_modules/@apollo/client/apollo-client.cjs.js
+++ b/node_modules/@apollo/client/apollo-client.cjs.js
@@ -5589,8 +5589,8 @@ var QueryData = (function (_super) {
return result;
};
_this.obsRefetch = function (variables) { var _a; return (_a = _this.currentObservable) === null || _a === void 0 ? void 0 : _a.refetch(variables); };
- _this.obsFetchMore = function (fetchMoreOptions) { return _this.currentObservable.fetchMore(fetchMoreOptions); };
- _this.obsUpdateQuery = function (mapFn) { return _this.currentObservable.updateQuery(mapFn); };
@kevinnguy
kevinnguy / sample-logic.js
Created May 6, 2019 23:21
scoot-handles-business-logic-blog
import { createLogic } from 'redux-logic';
const fetchUserLogic = createLogic({
type: USER_FETCH,
cancelType: USER_FETCH_CANCEL,
latest: true, // only provide the latest if fired many times
process: async ({ getState, action }, dispatch) => {
try {
const response = await fetch(`https://server/user/${action.payload}`);

What I Wish I'd Known About Equity Before Joining A Unicorn

Disclaimer: This piece is written anonymously. The names of a few particular companies are mentioned, but as common examples only.

This is a short write-up on things that I wish I'd known and considered before joining a private company (aka startup, aka unicorn in some cases). I'm not trying to make the case that you should never join a private company, but the power imbalance between founder and employee is extreme, and that potential candidates would

# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->

<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>

                     ART OF MONEY GETTING
            =====================================
                       by P. T. Barnum

                       ---------------
                     ART OF MONEY GETTING
#!/bin/sh
echo "What should the Application be called (no spaces allowed e.g. GCal)?"
read inputline
name="$inputline"
echo "What is the url (e.g. https://www.google.com/calendar/render)?"
read inputline
url="$inputline"