rsnext/packages/next
Steven 61fab923eb
Fix Image srcset to ensure the component's width is the largest possible image (#18236)
There was a bug when the user defines a width on the Image component, but a larger size image is requested.

This is because the browser uses the `srcset` to decide which image size to request and we had the srcset basically hardcoded.

This PR fixes the behavior so that the `srcset` will never be larger than the `width` defined on the component.

It also fixes a bug where the preload srcset did not match the img srcset.

- Related to #18147 
- Related to #18122
2020-10-26 14:29:52 +00:00
..
bin Correct comment on --help (#16391) 2020-08-20 13:32:55 +00:00
build Add next/image default loader errors (#18152) 2020-10-25 00:22:47 -05:00
cli Warn on duplicate Sass deps (#16398) 2020-08-20 16:05:29 +00:00
client Fix Image srcset to ensure the component's width is the largest possible image (#18236) 2020-10-26 14:29:52 +00:00
compiled Fix precompiled code (#18093) 2020-10-21 18:43:39 +00:00
export Ensure i18n support with AMP (#17923) 2020-10-15 18:00:08 -05:00
lib Expose dotenv loading under separate package (#17152) 2020-09-25 13:14:28 -05:00
next-server Image Optimization API should 404 when loader is not default (#18211) 2020-10-25 04:54:22 +00:00
pages Fix css dependency in /_error (#17301) 2020-10-21 12:11:18 +02:00
server Add initial changes for i18n support (#17370) 2020-10-07 21:11:01 +00:00
telemetry Record presence of reportWebVitals (#13155) 2020-05-20 18:44:39 +00:00
types Update to PostCSS 8. (#17415) 2020-10-21 12:31:07 +02:00
amp.d.ts Remove re-exports of default when they don't exist (#9450) 2019-11-18 20:11:59 -06:00
amp.js Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
app.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
app.js
babel.d.ts Remove re-exports of default when they don't exist (#9450) 2019-11-18 20:11:59 -06:00
babel.js
client.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
client.js
config.d.ts Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
config.js Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
constants.d.ts Remove default export from constants.d.ts (#8979) 2019-10-07 14:30:07 +02:00
constants.js Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
data.d.ts Remove re-exports of default when they don't exist (#9450) 2019-11-18 20:11:59 -06:00
data.js amp-bind data injection (#6840) 2019-04-02 16:09:34 +02:00
document.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
document.js
dynamic.d.ts Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
dynamic.js Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
error.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
error.js
head.d.ts Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
head.js Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00
image.d.ts Image component foundation (#17343) 2020-10-14 11:57:10 +02:00
image.js Image component foundation (#17343) 2020-10-14 11:57:10 +02:00
license.md Update year on license files 2020-04-21 12:24:08 +02:00
link.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
link.js
package.json v9.5.6-canary.14 2020-10-24 22:32:10 +02:00
README.md Improve Vercel's badge (#15946) 2020-08-06 12:35:36 -04:00
router.d.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
router.js
taskfile-babel.js Prefer builtin optional chaining and nullish coalescing (#16780) 2020-09-11 15:20:10 +00:00
taskfile-ncc.js Fix some webpack 5 deprecation warnings (#15797) 2020-08-03 12:57:17 +00:00
taskfile.js Make sure animated assets aren't de-animated by optimizer (#17974) 2020-10-17 19:22:10 +00:00
tsconfig.json Move next-server back into next package (#8613) 2019-09-04 10:00:54 -04:00

Next.js

Getting Started

Visit https://nextjs.org/learn to get started with Next.js.

Documentation

Visit https://nextjs.org/docs to view the full documentation.

Who is using Next.js?

Next.js is used by the world's leading companies. Check out the Next.js Showcase to learn more.

Contributing

Please see our contributing.md.

Authors