Copying CSS from copyspaces devtools
My workflow for CSS often involves me chatting in devtools, adding / modifying CSS in the browser and when the values ββmatch my needs, I copy the CSS and paste it into my .scss file.
Now that my copied CSS contains some spaces
formatting.
CSS in Chrome
div {
width: 100%;
background-color: yellow;
}
Copied code in editor
Now, when I copy the properties ( width
and background-color
) and paste them in your editor, I copy it as follows:
..width: 100%;
..background-color: yellow;
( dots
include spaces)
Is there a way to copy the CSS without spaces like:
width: 100%;
background-color: yellow;
Every time I paste in CSS it messes up my formatting, so I do a lot of unnecessary formatting. (e.g. removing spaces since I am using tabs and not spaces)
I know the spaces were added months ago before you could just copy the CSS without spaces.
I've searched for this too, and the closest I've found is in Chrome developer tools> settings> Sources> Default indentation. Unfortunately, there are no null spaces.
Cannot be copied from the style inspector without these spaces.
One solution is to click on the style sheet name next to the style, open the css tab in the Sources tab, then align the required code to the left by pressing Shift + Tab and then copy.
In most editors, this is simple: Ctrl-A then Shift-Tab.