show dbs
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
| // for multiple requests | |
| let isRefreshing = false; | |
| let failedQueue = []; | |
| const processQueue = (error, token = null) => { | |
| failedQueue.forEach(prom => { | |
| if (error) { | |
| prom.reject(error); | |
| } else { | |
| prom.resolve(token); |
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
| upstream fuel { | |
| # Defines a group of servers. Servers can listen on different ports. | |
| server IP:PORT fail_timeout=0; | |
| } | |
| upstream frontend { | |
| server IP:PORT fail_timeout=0; | |
| } |
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
| /** | |
| * Axios Request Wrapper | |
| * --------------------- | |
| * | |
| * @author Sheharyar Naseer (@sheharyarn) | |
| * @license MIT | |
| * | |
| */ | |
| import axios from 'axios' |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
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
| /* | |
| * Request: Javascript | |
| * | |
| * I would like to learn some basic concepts in JavaScript. Just as example, making a stopWatch and creating a racing game with few players which will have start and stop time for each player and choose one winner from them using the stopWatch object. | |
| */ | |
| // Design and Code a StopWatch | |
| // Sample Use Case: | |
| // var sw = new StopWatch(); | |
| // sw.start().stop().start().log(); |