other gists
🔗 TypeScript type toolbelt
🔗 TS/JS utility functions
note: Any ambient types referenced in the code samples below are defined in global.d.ts from the TypeScript type toolbelt.
other gists
🔗 TypeScript type toolbelt
🔗 TS/JS utility functions
note: Any ambient types referenced in the code samples below are defined in global.d.ts from the TypeScript type toolbelt.
other gists
🔗 TypeScript type toolbelt
🔗 React utils
note: Any ambient types referenced in the code samples below are defined in global.d.ts from the TypeScript type toolbelt.
This repository contains a collection of bookmarklets and script snippets that can be used to enhance the browsing experience.
Provides key binding to enable 2/5/10 sec rewind on Netflix and other sites.
scrollDown.js - Scroll down the page automatically
Calculate and display pool ranges in USD
other gists
🔗 TS/JS utility functions
🔗 React utils
| import CoreAPIService from './CoreAPIService'; | |
| import { CommentInterface } from '../interfaces/requestInterface'; | |
| class CommService { | |
| // CREATE | |
| addCommentToRequest = async (requestId: number, data: FormData) => | |
| CoreAPIService.post(`comments/${requestId}`, data, { 'Content-Type': 'multipart/form-data' }) | |
| .then<CommentInterface>(response => response.data); |
| // ==UserScript== | |
| // @name Neptune's Pride 2 devel - Triton userscript | |
| // @version 1 | |
| // @description This plugin works with Triton's data structures and performs advanced tasks on them. | |
| // @namespace http://qry.me/ | |
| // @author Vitezslav Ackermann Ferko (Qwerty), [email protected] [email protected] | |
| // @copyright 2014+, 2021+, Vitezslav Ackermann Ferko (Qwerty) | |
| // @licence Released under MIT licence | |
| // @downloadURL https://gist.githubusercontent.com/ackvf/464bc077f430cdd8677bbd9669d47605/raw/9285c7c3be05d5fac70cab8dac6db5589921d9b1/qscript-nptriton.devel.intro.monkey.js | |
| // //run-at document-start |
| /** | |
| * @name compose | |
| * @summary Composes Higher-Order-Functions from right to left so that they are executed from left to right. | |
| * note: To compose Higher-Order-Components, use compose.ts | |
| * | |
| * | |
| * @description | |
| * Two overloads are available: | |
| * A) Matches the composed signature of whole compose to the wrapped function. | |
| * B) As an escape hatch, it is possible to explicitly define the resulting OuterSignature with a generic, ignoring the HOFs types. |
| function callback(arg) { | |
| setTimeout(console.log, 0, arg, ' # 4 timeout '); | |
| setImmediate(console.log, arg, ' # 5 immediate'); | |
| process.nextTick(console.log, arg, ' # 2 nextTick '); | |
| (async () => { await undefined; console.log(arg, ' # 3 await '); })(); | |
| console.log(arg, '# 1 sync '); | |
| } | |
| setTimeout(callback, 0, ' # 4 timeout '); | |
| setImmediate(callback, ' # 5 immediate'); |