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
| [ | |
| { | |
| "name": "Afghanistan", | |
| "dial_code": "+93", | |
| "code": "AF" | |
| }, | |
| { | |
| "name": "Aland Islands", | |
| "dial_code": "+358", | |
| "code": "AX" |
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
| git log --all --grep="search text" |
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
| /* | |
| Tired of scrolling to one of the last photos on the page on Instagram? Let your | |
| browser do the scrolling for you! | |
| 31-05-2017 | |
| (c) 2017 - Loran Kloeze - loran@ralon.nl | |
| Usage | |
| - Go to https://www.instagram.com/instagram_handle/ (change instagram_handle in i.e. taylorswift) | |
| - Open up the console (F12) (Firefox users: type 'allow pasting' if you haven't done so yet) | |
| - Select the contents of this complete file and copy/paste it to the console and hit enter |
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
| [ | |
| "Aardvark", | |
| "Albatross", | |
| "Alligator", | |
| "Alpaca", | |
| "Ant", | |
| "Anteater", | |
| "Antelope", | |
| "Ape", | |
| "Armadillo", |
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
| const cors = require('cors') | |
| // Set `useWhitelist` to `false` if you want to accept all requests. | |
| const config = { | |
| useWhitelist: true | |
| } | |
| // Define from which origins requests are allowed. | |
| const whitelist = [ | |
| // 'https://fiddle.jshell.net', |
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
| [ | |
| {name: 'Afghanistan', code: 'AF'}, | |
| {name: 'Åland Islands', code: 'AX'}, | |
| {name: 'Albania', code: 'AL'}, | |
| {name: 'Algeria', code: 'DZ'}, | |
| {name: 'American Samoa', code: 'AS'}, | |
| {name: 'AndorrA', code: 'AD'}, | |
| {name: 'Angola', code: 'AO'}, | |
| {name: 'Anguilla', code: 'AI'}, | |
| {name: 'Antarctica', code: 'AQ'}, |
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
| downloadFile(token: string, url: string) { | |
| try { | |
| let headers = new HttpHeaders() | |
| .set( | |
| 'Authorization', | |
| `Bearer ${token}` | |
| ) | |
| .set('Accept', 'text/csv'); | |
| this.http | |
| .get(`${url}`, { |
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
| import { Directive, HostListener, Input, OnInit, Renderer2 } from '@angular/core'; | |
| import { DomController } from '@ionic/angular'; | |
| /** | |
| * Moves away the header when scrolling down. | |
| */ | |
| @Directive({ | |
| selector: '[appHideHeader]', | |
| }) | |
| export class HideHeaderDirective implements OnInit { |
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
| #!/bin/bash | |
| # see http://cmusphinx.sourceforge.net/wiki/tutorialam | |
| # see http://mnemonicplace.blogspot.de/2010/06/cmu-sphinx-error-wave2feat-error-while.html | |
| sudo apt-get install build-essential autoconf libtool automake python-dev subversion bison vim | |
| export PATH=/usr/local/bin:/usr/local/libexec/sphinxtrain:$PATH | |
| export LD_LIBRARY_PATH=/usr/local/lib | |
| export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig | |
| mkdir ~/tutorial | |
| cd ~/tutorial |
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
| const mysql = require('mysql'); | |
| const MySQLEvents = require('@rodrigogs/mysql-events'); | |
| const ora = require('ora'); // cool spinner | |
| const spinner = ora({ | |
| text: '🛸 Waiting for database events... 🛸', | |
| color: 'blue', | |
| spinner: 'dots2' | |
| }); | |
| const program = async () => { |
NewerOlder