This file contains hidden or 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
// El objeto Set permite almacenar valores únicos de cualquier tipo, incluso valores primitivos u referencias a objetos. | |
let set = new Set([1,2,3,3,4,4,5]) | |
console.log(set); | |
// Metodo .add() nos ayuda agregar nuevos datos a nustros Sets | |
set.add(7); | |
set.add(6); | |
set.add(6); | |
set.add(6); | |
set.add(8); |
This file contains hidden or 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
//Ejemplos de la expreciones this en javascript | |
//(Amplia mas en:https://developer.mozilla.org/es/docs/Web/JavaScript/Referencia/Operadores/this) | |
//Variable del objecto global | |
this.nombre ='Objecto global' | |
console.log(this.nombre); | |
function inprimir (){ | |
console.log(this.nombre);//Toma el valor del objecto global |
This file contains hidden or 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
// CLOSURE | |
const anotherFunction = () =>{ | |
var count = 0; | |
const countFuction =(value)=>{ | |
return count += value; | |
} | |
return countFuction; | |
} | |
let test = anotherFunction(); |
This file contains hidden or 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
version: '3.7' | |
services: | |
mongodb_container: | |
image: mongo:latest | |
environment: | |
MONGO_INITDB_ROOT_USERNAME: root | |
MONGO_INITDB_ROOT_PASSWORD: password | |
ports: | |
- 27017:27017 | |
volumes: |
This file contains hidden or 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
version: '3.8' | |
services: | |
postgres: | |
image: 'postgres:latest' | |
restart: always | |
volumes: | |
- './postgres_data:/var/lib/postgresql/data' | |
ports: | |
- "5432:5432" |
OlderNewer