I am a new user & it’s the latest version. The problem is that I cannot get any snippet to work! I copied a simple snippet to TextEdit & saved it. I placed it in the Snippets folder with the .css extension. The snippet shows up when I reload but it does not seem to work. I use the default dark theme with no plug-ins installed. What am I missing? Please help!!!
This is a difficult question to answer. Likely, the css is being loaded just fine, but the content fails to successfully select any element to apply its style to.
To test that the css is being loaded, put a unique string in the file as a comment (e.g. /* You can't find this in any other file. */). Then open the console (ctrl + shift+I) and search in the element windows for your string. It should appear in one of the loaded styles.
In the element window of the console, if you can select the elements you expected to style and expand the applied styles to see if yours is being overridden by a more specific selector.
In which file exactly should I put a unique string? I did open the console and the element window has a bunch of code in it. Sorry, I am totally new to this.
You’re not providing enough information for people to help! To begin with, please share your:
Appearance setting screenshot, especially the snippet part;
CSS file;
What you expect the CSS to accomplish.
Maybe the CSS file does work, it’s just faulty and doesn’t do what you want somehow… Simply “it doesn’t work” will make anyone who tries to help you scratch their head, so providing as much as detail on how it doesn’t work would be super helpful, thanks!
This worked!!! I was converting the RTFs directly to .css when I should have converted it to Plain Text first. I am new to Mac OS & had no idea about RTFs. Thank you for taking the time to help me out.
Good to hear you’ve got it working. Happy for you.
In TextEdit → Preferences, you can set whether you want new documents to default to Rich or Plain text. And it is always easy to convert between the two formats using the Format → Make Rich / Plain Text toggle.