In Sublime Text, you can automatically complete HTML header information by adding user code snippets. Specifically: character sets, headers, base URLs, stylesheets, and scripts.
Settings for automatically completing HTML header information in Sublime Text
In Sublime Text, you can The following steps set up automatic completion of HTML header information:
1. Open the user settings file
##2. Add User Code Snippets
In the user settings file, find theUser Code Snippets section and add the following snippet:
<code>html_head: 'html_head': { "scope": "text.html meta.head", "body": ''' <meta charset="${1:utf-8}"> <title>${2:Untitled Document}</title> <base href="${3:/}"> <link href="${4:styles.css}" rel="stylesheet"> <script src="${5:main.js}"></script> ''' }</code>
3. Save the settings file
Save and close the user settings file.Usage:
Start typinghtml_head in the HTML header area (
The above is the detailed content of How to set up sublime to automatically complete html header information. For more information, please follow other related articles on the PHP Chinese website!