Skip to content

Instantly share code, notes, and snippets.

View lgs's full-sized avatar

Luca G. Soave lgs

View GitHub Profile
@lgs
lgs / gist:7241e552a961aaea4499262c50a45df9
Created December 11, 2020 16:56 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@lgs
lgs / notion2blog.js
Created October 25, 2020 15:08 — forked from mayneyao/notion2blog.js
Notion.so > Personal Blog | custom domain + disqus comment
const MY_DOMAIN = "agodrich.com"
const START_PAGE = "https://www.notion.so/gatsby-starter-notion-2c5e3d685aa341088d4cd8daca52fcc2"
const DISQUS_SHORTNAME = "agodrich"
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request))
})
const corsHeaders = {
"Access-Control-Allow-Origin": "*",
// Includes functions for exporting active sheet or all sheets as JSON object (also Python object syntax compatible).
// Tweak the makePrettyJSON_ function to customize what kind of JSON to export.
var FORMAT_ONELINE = 'One-line';
var FORMAT_MULTILINE = 'Multi-line';
var FORMAT_PRETTY = 'Pretty';
var LANGUAGE_JS = 'JavaScript';
var LANGUAGE_PYTHON = 'Python';
@lgs
lgs / bash.sh
Created April 5, 2020 10:38 — forked from antony/bash.sh
Auth0 SSR Compatible Integration with Sapper
npm install --save express express-openid-connect
@lgs
lgs / Count Code lines
Created February 19, 2020 17:42 — forked from amitchhajer/Count Code lines
Count number of code lines in git repository per user
git ls-files -z | xargs -0n1 git blame -w | perl -n -e '/^.*\((.*?)\s*[\d]{4}/; print $1,"\n"' | sort -f | uniq -c | sort -n
@lgs
lgs / Auth.js
Created May 18, 2019 09:24 — forked from kaungmyatlwin/Auth.js
Firebase Vuex Auth Module
import firebase from 'firebase';
const state = {
userId: '',
};
const actions = {
login({ commit, state }, { email, password }) {
return new Promise((resolve, reject) => {
firebase.auth().signInWithEmailAndPassword(email, password)
@lgs
lgs / database.rules.json
Created May 4, 2019 11:31 — forked from codediodeio/database.rules.json
Common Database Rules for Firebase
// No Security
{
"rules": {
".read": true,
".write": true
}
}
@lgs
lgs / README.md
Created April 30, 2019 19:34
Vue + Firebase + Auth Demo

Vue + Firebase + Auth Demo

A simple App using Vue.js & Firebase with Auth.

See the DEMO.

@lgs
lgs / Hide Div When Clicked Outside It
Created April 9, 2019 17:31 — forked from slavapas/Hide Div When Clicked Outside It
Hide Div When Clicked Outside It
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Vanilla Javascript DropDown Menu Example</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div id="menu-dropdown">Menu &#9660;</div>
const { setContext } = require('apollo-link-context');
const { HttpLink } = require('apollo-link-http');
const { introspectSchema, makeRemoteExecutableSchema } = require('graphql-tools');
const fetch = require('node-fetch');
module.exports = function(api) {
api.createSchema(async function(graphql) {
const http = new HttpLink({
uri: 'http://example.com/api',
fetch