This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"env": { | |
"browser": true, | |
"es6": true, | |
"node": true | |
}, | |
"extends": ["airbnb"], | |
"globals": { | |
"document": false, | |
"escape": false, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Node template | |
# Logs | |
logs | |
*.log | |
npm-debug.log* | |
yarn-debug.log* | |
yarn-error.log* | |
# Runtime data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"initalState": { | |
"mylist": [], | |
"trends": [ | |
{ | |
"id": 2, | |
"slug": "tvshow-2", | |
"title": "In the Dark", | |
"type": "Scripted", | |
"language": "English", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Future versions of Hyper may add additional config options, | |
// which will not automatically be merged into this file. | |
// See https://hyper.is#cfg for all currently supported options. | |
module.exports = { | |
config: { | |
// choose either `'stable'` for receiving highly polished, | |
// or `'canary'` for less polished but more frequent updates | |
updateChannel: 'stable', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const perfil = { | |
nombre: 'Nikolas', | |
info: { | |
direccion: 'Nataniel Cox 1200' | |
} | |
} | |
const region = { | |
pais: 'Chile', | |
info: { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//////////////////////////////////////////////////////////////////////////////// | |
// Welcome to @reach/tooltip! | |
// | |
// Quick definitions: | |
// | |
// - "on rest" or "rested on": describes when the element receives mouse hover | |
// after a short delay (and hopefully soon, touch longpress). | |
// | |
// - "activation": describes a mouse click, keyboard enter, or keyboard space. | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { css } from 'styled-components' | |
const breakpoints = { | |
xs: '480px', | |
sm: '768px', | |
md: '992px', | |
lg: '1200px' | |
} | |
export const MQ = Object.keys(breakpoints).reduce((accumulator, label) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const joi = require('@hapi/joi') | |
const taskSchema = { | |
name: joi.string().required(), | |
description: joi.string().required() | |
} | |
module.exports = { | |
taskSchema | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const boom = require('@hapi/boom'); | |
const joi = require('@hapi/joi'); | |
function validate(data, schema) { | |
const { error } = joi.validate(data, schema); | |
return error; | |
} | |
function validationHandler(schema, check = 'body') { | |
return function(req, res, next) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const connectDB = require('./db') | |
const { ObjectID } = require('mongodb') | |
module.exports = { | |
createTask: async ({ task }) => { | |
const inputTask = Object.assign(task) | |
let db | |
let newTask | |
try { |
OlderNewer