View ts-type-map.ts
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
export enum EnumType { | |
Foo = 'Foo', | |
Bar = 'Bar', | |
} | |
export interface MapEnumTypeToDataType { | |
[EnumType.Foo]: { x: string }; | |
[EnumType.Bar]: { y: string }; | |
} |
View mac.ahk
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
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. | |
; #Warn ; Enable warnings to assist with detecting common errors. | |
SendMode Input ; Recommended for new scripts due to its superior speed and reliability. | |
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. | |
; CMD+Backspace -> delete to start of line | |
#BS::Send {LShift down}{Home}{LShift Up}{Del} | |
; Alt+Backspace -> delete to start of word |
View github-pr-mark-files-as-viewed.js
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
ignore = /packages\/.+\/(.eslintignore|package.json|jest.config.js)/ | |
clicks = $$('.js-toggle-user-reviewed-file-form').filter(f => !f._method && ignore.test(f.path.value)).map(f=>f.querySelector('input[type="checkbox"]')) | |
randomSleep = () => new Promise(r => setTimeout(r, Math.random() * 50)) | |
while (clicks.length) { await randomSleep(); console.log('marking as viewed...', clicks.length, ' to go'); clicks.pop().click() } |
View README.md
American Express - Add all offers to card at once
If you own an AMEX card, you can add a bunch of offers to the card in this link: https://global.americanexpress.com/offers/eligible
There are many offers, and they change all the time. Instead of clicking "Add to card" repeatedly, I created this bookmarklet.
In Chrome, add a new bookmark (right click on bookmarks bar -> "Add Page...") with the following URL:
View vscode-fileutils-keybindings.json
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
[ | |
{ | |
"key": "d", | |
"command": "fileutils.duplicateFile", | |
"when": "explorerViewletVisible && filesExplorerFocus && !inputFocus" | |
}, | |
{ | |
"key": "r", | |
"command": "fileutils.moveFile", | |
"when": "explorerViewletVisible && filesExplorerFocus && !inputFocus" |
View x.md
Summary Goes Here
```js
const test = 1
```
View _arrow-mixin.scss
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
@mixin arrow-helper($arrow-size, $arrow-color, $margin, $offset, $side, $align) { | |
@if $side == 'top' { | |
border-bottom-color: $arrow-color; | |
top: -2 * $arrow-size; | |
} | |
@if $side == 'bottom' { | |
border-top-color: $arrow-color; | |
bottom: -2 * $arrow-size; | |
} |
View cryptocurrency.js
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 valueInUSD = 1 | |
setInterval(() => { | |
valueInUSD = Math.max(valueInUSD + (Math.random() >= 0.5 ? 1 : -1) * Math.random() / (5 * Math.random()), 0.1) | |
console.log('valueInUSD', valueInUSD) | |
}, 10) |
View Sublime Text Packages.md
- Alignment
- ApplySyntax
- AutoBackups
- BracketGuard
- BracketHighlighter
- Case Conversion
- Color Highlighter
- ColorPicker
- ColorSchemeSelector
- Console Wrap for js
NewerOlder