Next.js 11.1 introduces an important security patch, ES Modules support, performance improvements, Rust-based tooling, 2x faster data fetching when pre-rendering, and more!
We're improving build performance across the entire stack with Next.js 11.1, featuring:
Update today by running npm i next@latest .
The Next.js team works with security researchers and auditors to prevent against vulnerabilities. We are thankful to Gabriel Benmergui from Robinhood for their investigation and discovery of an open redirect with pages/_error.js and subsequent responsible disclosure.
The reported issue did not directly harm users, but it could allow for phishing attacks by redirecting to an attacker's domain from a trusted domain. We've landed a patch in Next.js 11.1 preventing this open redirect from occurring, as well as security regression tests .
For more details, please read the public CVE . We recommend upgrading to the latest version of Next.js to…
This is an excerpt. The full article is published by Next.js Blog.
Answers to common questions regarding this article's topic, architecture, and practical applications.
We're improving build performance across the entire stack with Next.js 11.1, featuring:
How It Works
We're working on extensive ES Modules support in Next.js, both as input modules and as an output target. Starting with Next.js 11.1, you can now import npm packages using ES Modules (e.g. "type": "module" in their package.json) with an experimental flag. module.exports = {
// Prefer loading of ES Modules over CommonJS
experimental: { esmExternals: true },
};
ES Modules support includes backward compatibility to support the previous import beh
General
In Next.js 11, we introduced built-in ESLint support through next lint. Since its initial release, we've continued adding rules that help developers fix common mistakes in their applications.
General
The Next.js team works with security researchers and auditors to prevent against vulnerabilities. We are thankful to Gabriel Benmergui from Robinhood for their investigation and discovery of an open redirect with pages/_error.js and subsequent responsible disclosure. The reported issue did not directly harm users, but it could allow for phishing attacks by redirecting to an attacker's domain from a trusted domain. We've landed a patch in Next.js
General
When using next build and making numerous HTTP requests, we've improved performance by ~2x on average. For example, if you're using getStaticProps and getStaticPaths to fetch content from a Headless CMS, you should see noticeably faster builds. Next.js automatically polyfills node-fetch and now enables HTTP Keep-Alive by default. According to external benchmarks, this should make pre-rendering ~2x faster. To disable HTTP Keep-Alive for certain fe