This script is to take simplify duplicating components in webpages
style-extractor
The purpose of this script is to take simplify duplicating components in webpages.
How to use
-
Clone the repo
-
npm install
-
install typescript if you don’t have it.
-
> tsc
-
Copy the compiled output to the browser’s debugger.
-
Run the following in the brower’s console.
“`let css_selector = 'selector for an element'; // Produces output for react style_extractor(css_selector, true) // Produces output for inline stylesheets style_extractor(css_selector) ```
-
Wait for the output