-2

enter image description hereenter image description here Here is example it's only forking in html and not in css How to fix this problem?

It's dificult to find information on internet because i am the only one who have this problem

Monkey
  • 13
  • 2
  • Emmet (previously Zen Coding) is a set of text editor plugins allowing for high-speed coding in HTML, XML, XSL, and other structured code formats by expanding CSS-like expressions of elements into their corresponding representation. [View tag](https://stackoverflow.com/questions/tagged/emmet) – ATP Feb 07 '23 at 16:52
  • What are you expecting to get with the `pos` prefix? You are outside a ruleset. – Mark Feb 07 '23 at 18:06
  • @Mark pos is just an example i tried many coomands from here https://docs.emmet.io/cheat-sheet/ – Monkey Feb 07 '23 at 18:41
  • 1
    Almost all of those `css` emmet abbreviations are for inside a ruleset ONLY. They won't work if you are outside a ruleset as your image in the question shows. Try inside a ruleset. – Mark Feb 07 '23 at 18:59
  • @Mark you are right thank you i just started using css and didn't knew it work only inside of a rule set. html work even outside of ruleset – Monkey Feb 07 '23 at 19:07
  • Great, I added the info as an answer. I don't know why some people seem to think emmet doesn't work in a css file - it does. – Mark Feb 07 '23 at 19:14
  • **DO NOT post images of code, data, error messages, etc.** - copy or type the text into the question. [ask] – Rob Feb 07 '23 at 21:01

1 Answers1

0

In your case, the image shows you are outside of a css ruleset so there are many fewer emmet abbreviations that will work there. Your image shows what happens with a prefix of pos - it suggests things like :placeholder-shown, etc. that do appear as part of a css selector. If you are expecting the rest of the emmet abbreviations, like bg for background-color, use it IN a ruleset.


  • There seems to be some confusion from commenters (some since deleted) that emmet does not work in a css file - it does and has for some time.
Mark
  • 143,421
  • 24
  • 428
  • 436