Last active
March 25, 2024 13:22
-
-
Save sturmenta/eb93a8e1367d445b2bb81f5263db05f7 to your computer and use it in GitHub Desktop.
VSCode snippets
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
{ | |
// TODO: remember: save changes of this on https://gist.github.com/sturmenta/eb93a8e1367d445b2bb81f5263db05f7 | |
// | |
// ─── rust ───────────────────────────────────────────────────────────────────────────── | |
// | |
"println": { | |
"prefix": "prt", | |
"body": [ | |
"println!(\"$1 = {:#?}\", $1);" | |
], | |
"description": "println" | |
}, | |
// | |
// ──── js / ts ──────────────────────────────────────────────────────────────────────────── | |
// | |
"normal console.log": { | |
"prefix": "cl", | |
"body": [ | |
"console.log('$1')" | |
], | |
"description": "normal console.log" | |
}, | |
"console.log": { | |
"prefix": "clg", | |
"body": [ | |
"console.log(`$1`, $1)" | |
], | |
"description": "console.log" | |
}, | |
"console.log json": { | |
"prefix": "clj", | |
"body": [ | |
"console.log(`$1`, JSON.stringify($1, null, 2))" | |
], | |
"description": "console.log json" | |
}, | |
// ──────────────────────────────────────────────────────────────────────────────── | |
"console.log red": { | |
"prefix": "clgr", | |
"body": [ | |
"console.log('\u001b[1;31m $1\u001b[0m'); // log in red" | |
], | |
"description": "console.log red" | |
}, | |
"console.log green": { | |
"prefix": "clgg", | |
"body": [ | |
"console.log(`\u001b[1;32m $1\u001b[0m`); // log in green" | |
], | |
"description": "console.log green" | |
}, | |
"console.log yellow": { | |
"prefix": "clgy", | |
"body": [ | |
"console.log(`\u001b[1;33m $1\u001b[0m`); // log in yellow" | |
], | |
"description": "console.log yellow" | |
}, | |
// ──────────────────────────────────────────────────────────────────────────────── | |
"react-native border style": { | |
"prefix": "brr", | |
"body": [ | |
"borderWidth: 2,", | |
"borderColor: 'red',$1" | |
], | |
"description": "react-native border style" | |
}, | |
"styles": { | |
"prefix": "st", | |
"body": [ | |
"style={styles.$1}" | |
], | |
"description": "styles" | |
}, | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment