I hereby claim:
- I am SevInf on github.
- I am sevinf (https://keybase.io/sevinf) on keybase.
- I have a public key whose fingerprint is E483 737C 2AE2 4426 C2BC FCFC B89D 6839 8645 615E
To claim this, I am signing this object:
| # Instructions | |
| # 1. Download this script | |
| # 2. Add `source /path/to/the/script.sh` to your shell profile | |
| # 3. Reload the shell | |
| # 4. Use the command: | |
| # - `prisma-engine use /path/to/checkout/dir` for local checkout | |
| # - `prisma-engine use 12345` for github pull requests | |
| # - `prisma-engine unuse` for resetting all env variables and switching back | |
| # to default engine |
| // converts 255, 255, 255 -> #ffffff | |
| export function rgbToHex(r, g, b) { | |
| return '#' + to_hex(r) + to_hex(g) + to_hex(b); | |
| } | |
| function to_hex(color) { | |
| return color.toString(16); | |
| } | |
| // converts 255, 255, 255 -> #ffffff |
| // thing that exists and we already using | |
| class TreasureChest { | |
| contents = ['golden coin', 'cobweb']; | |
| } | |
| const chest = new TreasureChest(); | |
| console.log(chest.contents); |
| // 1 | |
| import { export1, export2 } from './original.mjs?mtime=0'; | |
| import { hmrClient } from '/hmrClient.mjs'; | |
| // 2 | |
| let export1Proxy = export1; | |
| let export2Proxy = export2; | |
| // 3 | |
| export { |
| import { increment } from './counter.mjs'; | |
| import { counter } from './counter.mjs?someQueryParameter'; | |
| console.log(counter); // prints 1 | |
| increment(); | |
| console.log(counter); // still prints 1 |
| export let counter = 1; | |
| export function increment() { | |
| counter++; | |
| } |
| import { text } from './text.mjs'; | |
| document.body.textContent = text; | |
| module.hot && module.hot.accept('./text.mjs', () => { | |
| // here text.mjs is updated and text variable has a new value | |
| document.body.textContent = text; | |
| }) |
| const replacements = { | |
| 'thenResolve': 'thenReturn', | |
| 'thenReject': 'thenThrow', | |
| 'fcall': 'try' | |
| } | |
| export default function transformer(file, api) { | |
| const j = api.jscodeshift; | |
| const sourceCalls = []; | |
| const f = j(file.source); |
I hereby claim:
To claim this, I am signing this object:
| async(function*() { | |
| console.log('start'); | |
| yield asyncFunction(); | |
| var value = yield asyncFunction(); | |
| console.log('value', value); | |
| }); | |
| function asyncFunction() { | |
| return new Promise((resolve, reject) => { | |
| setTimeout(() => { |