Update Image Size in Sublime Text
Emmet's Update Image Size
Place Cursor in <img> Tag
Click anywhere inside an existing img tag with a src attribute.
Open Command Palette
Cmd-Shift-P (Mac) or Ctrl-Shift-P (Windows).
Find Emmet: Update Image Size
Sublime calls Emmet, which reads the actual image dimensions.
Width & Height Auto-Updated
The width and height attributes update to match the real image.
Noble Desktop's Full-Stack Web Development Certificate covers HTML, CSS, JavaScript, and the modern web stack.
Sublime Text with Emmet allows you to automatically update width and height attributes on img tags. Place the cursor inside an img tag and hit Ctrl–Shift–I (Mac) or Ctrl–U (Windows).

Note: This keystroke requires Emmet to be installed in Sublime Text. For instructions on how to install Emmet, download our Sublime Text Enhancements Installation Guide.