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
| ########## Install NGINX ############## | |
| # Install software-properties-common package to give us add-apt-repository package | |
| sudo apt-get install -y software-properties-common | |
| # Install latest nginx version from community maintained ppa | |
| sudo add-apt-repository ppa:nginx/stable | |
| # Update packages after adding ppa |
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
| /** | |
| * Box triangle with shadow box | |
| */ | |
| .ant-dropdown-placement-bottomLeft ul { | |
| box-shadow: 0 0 8px rgba(0, 0, 0, 0.5); | |
| position: relative; | |
| top: 20px; | |
| left: 20px; | |
| width: 100px | |
| } |
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 React from 'react'; | |
| export default class RequestTest extends React.PureComponent { | |
| constructor(props, context) { | |
| super(props); | |
| this.state = { | |
| pageSize: 500, | |
| concurrent: true, | |
| concurrentNumber: 5, |
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 curry = fn => { | |
| if (fn.length <= 1) return fn; | |
| const generator = (...args) => { | |
| if (fn.length === args.length) { | |
| return fn(...args); | |
| } else { | |
| return (...args2) => generator(...args, ...args2); | |
| } | |
| }; | |
| return generator; |
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
| { | |
| "inbounds": [ | |
| { | |
| "port": 1080, // Listening port | |
| "protocol": "socks", // Incoming protocol is SOCKS 5 | |
| "sniffing": { | |
| "enabled": true, | |
| "destOverride": ["http", "tls"] | |
| }, | |
| "settings": { |
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
| let calculateEachMonth = () => { | |
| const data = {}; | |
| const dataYear = {}; | |
| document.querySelectorAll('#list > div > table > tbody > tr').forEach(row => { | |
| const dateCell = row.querySelector('td:nth-child(1)').innerHTML; | |
| const money = Number(row.querySelector('td:nth-child(2)').innerHTML.replace(/[^0-9\.]/g, '')); | |
| const yearMonth = 'T' + dateCell.replace(/月.*/g, '').replace(/ /, ''); | |
| const year = 'T' + dateCell.replace(/ \d*月.*/g, ''); | |
| if (data[yearMonth]) { | |
| data[yearMonth] += money; |
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
| # https://github.com/sass/node-sass/issues/2165 | |
| docker pull node | |
| # cd to working dir | |
| # start docker | |
| docker run -it -v $PWD:/code -p 3001:3000 node bash | |
| npm i -g n | |
| n 8.10.0 |
OlderNewer