Nombre | Windows | Linux |
---|---|---|
nvm | https://github.com/coreybutler/nvm-windows/releases | https://github.com/creationix/nvm |
node (con nvm) | nvm install (numero de la ultima version) | nvm install --lts |
npm i -g typescript tslint eslint bower grunt-cli gulp-cli aurelia-cli firebase-tools | npm i -g typescript tslint eslint bower grunt-cli gulp-cli aurelia-cli firebase-tools | npm i -g typescript tslint eslint bower grunt-cli gulp-cli aurelia-cli firebase-tools |
docker | https://store.docker.com/editions/community/docker-ce-desktop-windows | https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-18-04 |
Git | https://git-scm.com/download/win | sudo apt install git |
vscde | https://code.visualstudio.com/ | https://code.visualstudio.com/ |
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
// importamos la libreria | |
const fs = require('fs'); | |
//puede llevar cualquier nombre, generalmente | |
// se sigue la convencion de usar el mismo nombre que la libreria | |
// fs es parte de la libreria estandard | |
/** | |
* @param {string} directorio de destino | |
* @param {string} texto a escribir dentro del archivo |
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
// importamos la libreria | |
const fs = require('fs'); | |
//puede llevar cualquier nombre, generalmente | |
// se sigue la convencion de usar el mismo nombre que la libreria | |
// fs es parte de la libreria estandard | |
/** | |
* @param {string} directorio de destino | |
* @param {string} texto a escribir dentro del archivo |
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 winston = require('winston') | |
const customLogger = new (winston.Logger)({ | |
transports: [ | |
new (winston.transports.Console)({ | |
colorize: true, | |
level: 'silly', | |
json: false | |
}), | |
new (winston.transports.File)({ // add as many as you want | |
name: 'verbose-file', |
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
/** | |
Let say I have a fancy class with some fancy methods in services|helpers | |
withoud any sails logic in it, eg no waterline, no sails.*.*.js | |
*/ | |
class FancyService { | |
async fancyMethod() { | |
return await Promise.resolve('Fancy Result') | |
} | |
} |
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
<template> | |
<v-toolbar dark> | |
<v-btn icon @click="pickAudio"> | |
<v-icon>library_music</v-icon> | |
</v-btn> | |
<v-btn icon v-if="file.isAvailable && !isPlaying" @click="play"> | |
<v-icon>play_arrow</v-icon> | |
</v-btn> | |
<v-btn icon v-else-if="file.isAvailable && isPlaying" @click="pause"> | |
<v-icon>pause</v-icon> |
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
<template> | |
<require from="./event-case"></require> | |
<h1>${message}</h1> | |
<p> | |
Looking at the console, you can see the event was dispatched, | |
but it was not caught by aurelia's binding <br /> | |
<event-case ref="case1" my-click.trigger="onClick($event)"></event-case> | |
<event-case ref="case2" my-click.delegate="onClick($event)"></event-case> | |
</p> | |
<p> |
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
/// <reference types="aurelia-loader-webpack/src/webpack-hot-interface"/> | |
import { Aurelia } from 'aurelia-framework' | |
import environment from './environment'; | |
import { PLATFORM } from 'aurelia-pal'; | |
import { defineCustomElements } from '@ionic/core/loader'; | |
import { defineCustomElements as defineShared } from '@project/shared/dist/loader'; | |
import '@ionic/core'; | |
import { setupConfig } from '@ionic/core'; | |
import authConfig from 'auth.config'; |
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
/// <reference types="aurelia-loader-webpack/src/webpack-hot-interface"/> | |
import { Aurelia } from 'aurelia-framework' | |
import environment from './environment'; | |
import { PLATFORM } from 'aurelia-pal'; | |
import { defineCustomElements } from '@ionic/core/loader'; | |
import { defineCustomElements as defineShared } from '@project/shared/dist/loader'; | |
import '@ionic/core'; | |
import { setupConfig } from '@ionic/core'; | |
import authConfig from 'auth.config'; |
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
module Unsplash | |
open FSharp.Data | |
open System.IO | |
open System.Net.Http | |
type RandomPhoto = | |
JsonProvider<"https://api.unsplash.com/photos/random?client_id=<YOUR ACCESS TOKEN>"> | |
let getRandomPhoto = RandomPhoto.AsyncGetSample() |
OlderNewer