Skip to content

Instantly share code, notes, and snippets.

View vinibgoulart's full-sized avatar
🎯
Focusing

Vinicius Blazius Goulart vinibgoulart

🎯
Focusing
View GitHub Profile
@sibelius
sibelius / woovi_job.md
Last active August 31, 2024 16:18
Woovi Job Description
@sibelius
sibelius / apiLog.ts
Created April 13, 2021 15:01
fetch api with log
export const apiWithLog = (init, options) => {
const end = timeSpan();
return fetch(init, options).then(async (response) => {
const durationTime = end();
const text = await response.text();
let json;
try {
@jgcmarins
jgcmarins / babel.config.js
Created April 24, 2020 23:37
Webpack configs for Node.js backends to run both locally and on AWS Lambda
module.exports = {
presets: [
'@babel/preset-react',
[
'@babel/preset-env',
{
targets: {
node: 'current',
},
},
@sibelius
sibelius / createLoader.tsx
Created February 26, 2020 18:53
createLoader used on react europe relay workshop
// eslint-disable-next-line
import { mongooseLoader } from '@entria/graphql-mongoose-loader';
import DataLoader from 'dataloader';
import { ConnectionArguments } from 'graphql-relay';
import { Model, Types } from 'mongoose';
import { buildMongoConditionsFromFilters } from '@entria/graphql-mongo-helpers';
import { validateContextUser } from './validateContextUser';
import { withConnectionCursor } from './withConnectionCursor';
@silver-xu
silver-xu / ts-boilerplate.md
Last active October 31, 2024 12:16
Setup a Node.js project with Typescript, ESLint, Prettier, Husky

Setup a Node.js project with Typescript, ESLint, Prettier, Husky

1_D8Wwwce8wS3auLAiM3BQKA

Starting a personal node project could be easy; starting a team node project could be challenging.

I am a developer currently working in SEEK Australia.

In my experience, common mistakes developer make when starting a projects are:

  • No Linting
@diego3g
diego3g / NODE.md
Last active November 17, 2024 02:12
VSCode Settings (Updated)

⚠️ Note!

With VSCode version 1.94, the APC extension broke and there is no fix yet.

So, for those having issues with APC after the VSCode update, I recommend downloading the previous version of VSCode for now (https://code.visualstudio.com/updates/v1_93) and setting updates to manual by adding this to the editor's configuration:

"update.mode": "manual",
@hyb175
hyb175 / realmMock.js
Last active June 13, 2024 02:45
Realm Mock for jest
// https://github.com/realm/realm-js/issues/370#issuecomment-270849466
export default class Realm {
constructor(params) {
this.schema = {};
this.callbackList = [];
this.data = {};
this.schemaCallbackList = {};
params.schema.forEach((schema) => {
this.data[schema.name] = {};
});