I hereby claim:
- I am geovanisouza92 on github.
- I am geovanisouza92 (https://keybase.io/geovanisouza92) on keybase.
- I have a public key whose fingerprint is 8B5C C25C D7BC 4E02 EF4D 1C58 2BD4 9AD7 EF5B 8C6A
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
export function LoginForm() { | |
const { register, handleSubmit, formState: { isDirty } } = useForm(); | |
useBeforeUnload((event) => { | |
if (isDirty) event.preventDefault(); | |
}); | |
const login = (data) => console.log(data); | |
return ( |
const express = require('express'); | |
const bodyParser = require('body-parser'); | |
const cookieParser = require('cookie-parser'); | |
const passport = require('passport'); | |
const LocalStrategy = require('passport-local').Strategy; | |
const { Strategy: JwtStrategy, ExtractJwt } = require('passport-jwt'); | |
const FacebookStrategy = require('passport-facebook'); | |
const GoogleStrategy = require('passport-google-oidc'); | |
const { MultiSamlStrategy } = require('passport-saml'); |
Nesse modelo, as atualizações são transmitidas por websockets (socket.io) e focadas nas abas/janelas dos usuários da mesma empresa.
Vantagem: a página é carregada já com dados, logo, se o usuário está com uma máquina mais modesta ou internet mais lenta, vai evitar loading/spinner.
/* eslint-disable @typescript-eslint/no-non-null-assertion */ | |
type Job = { | |
id: number; | |
code: string; | |
name: string; | |
jobType: string; | |
status: string; | |
publicationType: string; | |
recruiterId: number; |
async function forEachSerial(cb, arr) { | |
await arr.reduce(async (prevPromise, value) => { | |
await prevPromise; | |
return cb(value); | |
}, Promise.resolve()); | |
} | |
async function forEachParallel(cb, arr) { | |
await Promise.all(arr.map(cb)); | |
} |
package main | |
import ( | |
"github.com/geovanisouza92/go-tasks" | |
"github.com/geovanisouza92/go-tasks/vcs/git" | |
"github.com/geovanisouza92/go-tasks/build/docker" | |
"github.com/geovanisouza92/go-tasks/deploy/kubernetes" | |
) | |
func main() { |
class Token { | |
nextRange() { | |
return `${this._range}-`; | |
} | |
feed(response) { | |
this._range = response.headers.Range; | |
} | |
} |
const Benchmark = require('benchmark'); | |
const suite = new Benchmark.Suite(); | |
const A = Array(3).fill(null).map((_, index) => index + 1); | |
const B = A.map((a) => [a, a * -1]); | |
suite | |
.add('cartesianProduct_gen', function () { for (const _ of cartesianProduct_gen(B.slice())) { } }) | |
.add('cartesianProduct_loop', function () { for (const _ of cartesianProduct_loop(...B.slice())) { } }) | |
.add('cartesianProduct_genLoop', function () { for (const _ of cartesianProduct_genLoop(B.slice())) { } }) |