How can I add an extra line of code so when I type “! + tab” there’s more to it than the default?
Would I be able to use that same shortcut and add the
link rel="stylesheet" type="text/css" href="style.css" />
I don’t see why not. Are you having difficulty doing so?
I haven’t tried yet. I thought it would conflict with the one emmet already has.
The conflict isn’t going to cause an error or anything. One of the two will get higher priority, and I would expect that to be the one you have in
I can’t seem to get it to work with my own snippet
Please post a screenshot of your
Okay, in order to make a multiline
body, you need special syntax. It’ll look like this:
'HTML': prefix: 'html' body: ''' <!DOCTYPE html> <html> <head> </head> </html> '''
(The keys can be either quoted or unquoted, as long as they’re one word. I find it easier to read when they’re unquoted unless they have to be quoted to work.)
The top-level key needs to be the scope where the snippet is going to apply. So you need to add a scope value and indent the following three lines. You have two options:
'*': 'HTML': prefix: 'html' body: ''' <!DOCTYPE html> <html> <head> </head> </html> '''
'text.html.basic': 'HTML': prefix: 'html' body: ''' <!DOCTYPE html> <html> <head> </head> </html> '''
The first example will apply to all files, while the second will only work in HTML documents.
I was looking for the scope for the “language-html” and there’s not one. What should I do to add one?
The scope is
text.html.basic. You can see it in the settings panel for the
Packages, scroll down to
language-html, and click on it.
I found it but I’m not getting it. Is it easier to add a snippet to brackets?
What are you having difficulty with? Are you having trouble with the snippets I gave you?
I tried what is shown in the picture that I posted 14 days again but added the “‘text.html.basic’:” above the HTML and then tried it but it didn’t work. Sorry I can’t add the picture I’m referring to to make it easier for you. I had to take my MacBook Pro to Apple to get worked on because the display was messing up.
Would you still be able to help me?