Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View krolow's full-sized avatar

Vinícius Krolow krolow

View GitHub Profile
@krolow
krolow / example-react-form-hook.js
Last active January 14, 2019 16:58
Simple react form using hooks
import React from 'react';
import { useRef } from 'react';
export default function AddMemberPage({ addMember }) {
const formRef = useRef();
async function handleSave(event) {
event.preventDefault();
@krolow
krolow / how-to-start-side-project.md
Created February 16, 2018 01:34
I like to build side projects, I will describe here how I start those

Idea

Name / Email

Once you have a name I do use godaddy.com after register I go to cloudflare and create a register for domain, and get the DNS NS from cloudflare to go update it in godaddy.

Once the DNS is updated in godaddy, I like to setup a custom email like: hello@project.com, twitter@project.com etc... To do such a thing, I normally go in gmail and register a new email myproject@gmail.com and so I go to https://improvmx.com/ that supports email forward. I get the two MX DNS and go back to cloudflare to add them. Once the DNS is updated

ncal | grep -vE "^S|^ |^$" | sed "s/[[:alpha:]]//g" | fmt -w 1 | sort -n | wc -l
- api2 token expires after a given period, we should automate the token refresh
@krolow
krolow / colors.txt
Created September 30, 2016 14:02
Slack atom dark ui sidebar
#20242A,#272B33,#4182C4,#FFFFFF,#353B45,#FFFFFF,#96C277,#DF6A73
@krolow
krolow / Readme.md
Created August 15, 2016 17:21 — forked from rauchg/Readme.md

Minimum Viable Async with Node 6

With the release of Node 6.0.0, the surface of code that needs transpilation to use ES6 features has been reduced very dramatically.

This is what my current workflow looks like to set up a minimalistic and fast microservice using micro and async + await.

The promise

@krolow
krolow / brasileirao-ical.js
Last active August 25, 2016 02:04
Brasileirao em node.js
var request = require('request');
var Handlebars = require('handlebars');
var crypto = require('crypto');
var CHAMPIONSHIP_URL = 'https://webtask.it.auth0.com/api/run/wt-krolow-gmail_com-0/brasileirao?serie=%serie%';
function fetchChampionship (serie) {
return new Promise(function (resolve, reject) {
h1, h2, h3, h4, h5, h6 {
font-family: 'OfficinaSerifStd-Bold', 'Baskerville', 'Cambria', 'Constantia', 'Palatino Linotype', 'Palatino', 'Georgia', 'Times', 'Times New Roman', serif;
font-weight: bold;
color: rgb(51, 51, 51);
line-height: 30px;
}
p {
margin: 15px 0;
font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
font-size: 14px;