rsnext/packages/font
Hannes Bornö 7fd0f7752a
Reuse file when shared by several google font variants (#42480)
If a Google font is available as a variable font - the different variants may reuse the same file when you ask for specific variants. Make sure to reuse the same file and don't make additional requests.

## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have a helpful link attached, see `contributing.md`

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR.
- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have a helpful link attached, see `contributing.md`

## Documentation / Examples

- [ ] Make sure the linting passes by running `pnpm build && pnpm lint`
- [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
2022-11-04 18:47:42 +00:00
..
google Font loader default config (#41628) 2022-10-21 18:08:37 -07:00
local Font loader default config (#41628) 2022-10-21 18:08:37 -07:00
src Reuse file when shared by several google font variants (#42480) 2022-11-04 18:47:42 +00:00
fontkit.js Local font files adjust fallbacks (#41180) 2022-10-10 18:54:34 +00:00
package.json v13.0.2 2022-11-03 16:20:51 -07:00
README.md Update font links and add missing error (#41910) 2022-10-26 23:00:40 -07:00
tsconfig.json Add next font package (#40227) 2022-09-21 15:10:24 -07:00

@next/font

@next/font includes built-in automatic self-hosting for any font file. This means you can optimally load web fonts with zero layout shift, thanks to the underlying CSS size-adjust property used.

This new font system also allows you to conveniently use all Google Fonts with performance and privacy in mind. CSS and font files are downloaded at build time and self-hosted with the rest of your static assets. No requests are sent to Google by the browser.

Read more