Skip to content

Instantly share code, notes, and snippets.

View olafwrieden's full-sized avatar
🔥
git: Committed for life

Olaf Wrieden olafwrieden

🔥
git: Committed for life
View GitHub Profile
@GiselaMD
GiselaMD / client.ts
Last active September 23, 2021 11:22
ApolloClient with token authentication and refresh token
import { HttpLink } from 'apollo-link-http';
import { ApolloClient, DefaultOptions } from 'apollo-client';
import { InMemoryCache, NormalizedCacheObject } from 'apollo-cache-inmemory';
import { ApolloLink } from 'apollo-link';
import { resolvers } from './resolvers';
import { typeDefs } from './schema/typeDefs';
import { errorLink } from './error';
import { requestLink } from './requestLink';
import customFetch from './customFetch';

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?

@JesusMurF
JesusMurF / users.js
Created November 16, 2016 10:21
How to encrypt password in Sequelize
import Sequelize from 'sequelize'
import bcrypt from 'bcrypt-nodejs'
import connection from '../config/db'
require('sequelize-isunique-validator')(Sequelize)
let User = connection.define('user', {
firstName: {
type: Sequelize.STRING(50),
allowNull: false,
@lukas-h
lukas-h / license-badges.md
Last active September 17, 2024 21:32
Markdown License Badges for your Project

Markdown License badges

Collection of License badges for your Project's README file.
This list includes the most common open source and open data licenses.
Easily copy and paste the code under the badges into your Markdown files.

Notes

  • The badges do not fully replace the license informations for your projects, they are only emblems for the README, that the user can see the License at first glance.

Translations: (No guarantee that the translations are up-to-date)

@madx
madx / .gitconfig
Last active August 3, 2022 10:09
Git aliases for a simple tag based Heroku deploy strategy
[alias]
deploy = ! git checkout master && git tag-deploy && git push && git push --tags && git push production master
deploy-staging = ! git checkout develop && git tag-deploy staging && git push && git push --tags && git push staging develop:master
tag-deploy = ! sh -c 'git tag "${0:-production}-`date +%Y%m%d%H%M%S`-$USER"'