Optimizing Images with @sveltejs/enhanced-img
Serve correctly sized, next-gen images with the enhanced:img component.
Image Optimization
The @sveltejs/enhanced-img plugin generates responsive, modern-format images at build time.
Install
Add to dev dependencies and register in Vite config.
npm install -D @sveltejs/enhanced-imgAll lessons in this course
- Code Splitting and Dynamic Imports
- Optimizing Images with @sveltejs/enhanced-img
- Lazy Loading Components
- Profiling SvelteKit Apps