Last active
September 3, 2019 20:07
-
-
Save tomhodgins/37eb3839190f647d1059dcf0aff492a6 to your computer and use it in GitHub Desktop.
Generate a simple reset/preset for an element and it's children. Run with node, supply your selector as the command line argument.
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 selector | |
// Deno CLI support | |
if (typeof Deno !== 'undefined') { | |
[selector] = Deno.args.slice(1) | |
} | |
// Node CLI support | |
if (typeof process !== 'undefined') { | |
[selector] = process.argv.slice(2) | |
} | |
console.log(` | |
${selector || 'selector'}, | |
${selector || 'selector'} * { | |
box-sizing: border-box; | |
text-rendering: optimizeLegibility; | |
-webkit-font-smoothing: antialiased; | |
-moz-osx-font-smoothing: grayscale; | |
font-kerning: auto; | |
} | |
`.trim()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment