Emmet is a popular plugin available for multiple IDEs including VSCode.
By Default it works when you are on .html
file.
You can also make it work on .js
files when working with JSX.
Open Settings in VSCode:
Ctrl + ,
Navigate to Workspace tab > Extensions
Use “Edit in settings.json
"
Add following config to the settings.json
file:
{
"emmet.includeLanguages": {
"javascript": "javascriptreact"
}
}
Emmet should start working in .js
files now.
Thanks to Eshwaren M