- 18 8月, 2020 5 次提交
-
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
This pull request adds a test case for the reproduction provided in #12445. This bug is specifically caused when loading the next page before navigation has actually occurred. --- Fixes #12445
-
由 JJ Kasper 提交于
-
由 Kristoffer K 提交于
-
由 Kevin Mårtensson 提交于
AMP will still not work correctly when switching between non-AMP and AMP pages in development mode because of https://github.com/vercel/next.js/blob/canary/packages/next/build/babel/plugins/next-page-config.ts#L116-L120. Fixes #15704.
-
- 17 8月, 2020 4 次提交
-
-
由 JJ Kasper 提交于
This fixes the incorrect `/_next/data` URL being generated on client transition due to the `as` value passed to `getRouteInfo` having the `basePath` which is used while interpolating the values for dynamic routes, specifically root catch-all routes. A regression test has also been added to ensure this is working Closes: https://github.com/vercel/next.js/issues/15747
-
由 Tim Neutkens 提交于
-
由 Tim Neutkens 提交于
-
由 Sergey Rubanov 提交于
Co-authored-by: NTim Neutkens <timneutkens@me.com> Co-authored-by: Nkodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
-
- 16 8月, 2020 3 次提交
-
-
由 cargallo 提交于
Added a section in readme with the proper use of the plugin with next-compose-plugins ^2.0.0, otherwise it doesn't work
-
由 Tuan Nguyen 提交于
Just noticed a couple of tiny grammar errors.
-
由 Rafael Almeida 提交于
* Update with-storybook example * Delete with-storybook-typescript example * Add TypeScript section to the README Co-authored-by: Nkodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
-
- 15 8月, 2020 3 次提交
-
-
由 Joe Haddad 提交于
-
由 JJ Kasper 提交于
This updates to not automatically append params to the query for rewrites if one or more of the params are already used in the destination's path. No other behavior is being changed and if the user still wants the params in the query after using them in the destination's path they can manually add them like with redirects. Closes: https://github.com/vercel/next.js/issues/15626
-
由 Artem Zakharchenko 提交于
* Add MSW usage example * Updated example * Added .gitignore * Added .gitignore in the right place lol Co-authored-by: NLuis Alvarez <luis@vercel.com>
-
- 14 8月, 2020 9 次提交
-
-
由 Joe Haddad 提交于
Instead of reading the `BuildManifest` and passing it to `/_document`, it should be able to read it for itself. --- Fixes #16182
-
由 Kristoffer K 提交于
**What's the problem this PR addresses?** https://github.com/vercel/next.js/pull/16048 stopped bundling `caniuse-lite` but didn't declare it as a dependency https://github.com/yarnpkg/berry/runs/972037981?check_suite_focus=true#step:5:75 **How did you fix it?** Add `caniuse-lite` as a dependency --- cc @Timer As mentioned in https://github.com/vercel/next.js/issues/14157#issuecomment-667328984 I looked into adding a PnP e2e test but the use of the `gist` protocol stopped me from getting it to work since v2 doesn't support that yet. Would it be possible to change this to one of the supported protocols (https://yarnpkg.com/features/protocols)? https://github.com/vercel/next.js/blob/636672755004c756eefcddb5d4ccabbc1855e75a/packages/next/package.json#L208
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
This pull request edits the `BuildManifest` that is sent to `/_document` instead of modifying a single input array to decouple its implementation details. Optimally, we'd eliminate the `files` key all together. --- Related to #16182
-
由 JJ Kasper 提交于
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
Fixes #16166
-
- 13 8月, 2020 12 次提交
-
-
由 Joe Haddad 提交于
Really basic one! Needed for `next/client`.
-
由 Joe Haddad 提交于
This reduces the code as suggested: https://github.com/vercel/next.js/pull/15231#discussion_r469691649. Removes these bloated Babel helpers: ```diff @@ -678,80 +678,6 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI var _createClass = __webpack_require__("W8MJ"); - function _createForOfIteratorHelper(o, allowArrayLike) { - var it; - if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { - if ( - Array.isArray(o) || - (it = _unsupportedIterableToArray(o)) || - (allowArrayLike && o && typeof o.length === "number") - ) { - if (it) o = it; - var i = 0; - var F = function F() {}; - return { - s: F, - n: function n() { - if (i >= o.length) return { done: true }; - return { done: false, value: o[i++] }; - }, - e: function e(_e) { - throw _e; - }, - f: F - }; - } - throw new TypeError( - "Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method." - ); - } - var normalCompletion = true, - didErr = false, - err; - return { - s: function s() { - it = o[Symbol.iterator](); - }, - n: function n() { - var step = it.next(); - normalCompletion = step.done; - return step; - }, - e: function e(_e2) { - didErr = true; - err = _e2; - }, - f: function f() { - try { - if (!normalCompletion && it["return"] != null) it["return"](); - } finally { - if (didErr) throw err; - } - } - }; - } - - function _unsupportedIterableToArray(o, minLen) { - if (!o) return; - if (typeof o === "string") return _arrayLikeToArray(o, minLen); - var n = Object.prototype.toString.call(o).slice(8, -1); - if (n === "Object" && o.constructor) n = o.constructor.name; - if (n === "Map" || n === "Set") return Array.from(o); - if ( - n === "Arguments" || - /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) - ) - return _arrayLikeToArray(o, minLen); - } - - function _arrayLikeToArray(arr, len) { - if (len == null || len > arr.length) len = arr.length; - for (var i = 0, arr2 = new Array(len); i < len; i++) { - arr2[i] = arr[i]; - } - return arr2; - } - exports.__esModule = true; exports.hasBasePath = hasBasePath; exports.addBasePath = addBasePath; @@ -1864,28 +1790,16 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI } // handle resolving href for dynamic routes if (!pages.includes(cleanPathname)) { - var _iterator = _createForOfIteratorHelper(pages), - _step; - - try { - for (_iterator.s(); !(_step = _iterator.n()).done; ) { - var page = _step.value; - - if ( - (0, _isDynamic.isDynamicRoute)(page) && - (0, _routeRegex.getRouteRegex)(page).re.test( - cleanPathname - ) - ) { - parsedHref.pathname = addBasePath(page); - break; - } + // eslint-disable-next-line array-callback-return + pages.some(function(page) { + if ( + (0, _isDynamic.isDynamicRoute)(page) && + (0, _routeRegex.getRouteRegex)(page).re.test(cleanPathname) + ) { + parsedHref.pathname = addBasePath(page); + return true; } - } catch (err) { - _iterator.e(err); - } finally { - _iterator.f(); - } + }); } return parsedHref; @@ -2069,10 +1983,9 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI } if (cancelled) { - var _err = new Error("Loading initial props cancelled"); - - _err.cancelled = true; - throw _err; + var err = new Error("Loading initial props cancelled"); + err.cancelled = true; + throw err; } return data; ```
-
由 Tim Neutkens 提交于
-
由 JJ Kasper 提交于
Co-authored-by: NTim Neutkens <timneutkens@me.com>
-
由 Joe Haddad 提交于
This PR removes a legacy router method that was used for old-style HMR, now replaced by Fast Refresh. This method was not public: ```tsx export type NextRouter = BaseRouter & Pick< Router, | 'push' | 'replace' | 'reload' | 'back' | 'prefetch' | 'beforePopState' | 'events' | 'isFallback' > ``` Even if someone found this method, it's highly unlikely they could use it successfully—it required the full module object.
-
由 Joe Haddad 提交于
This PR dedupes the `ComponentRes` type to now align with the `loadPage` return type.
-
由 Thorsten Schaeff 提交于
r? @lfades @timothyis cc @kiwicopple @awalias Adding a realtime chat example showing how to implement authentication and realtime data syncing with supabase.io :)
-
由 madiknox 提交于
Fixes #14737
-
由 madiknox 提交于
This is my very first PR, I'm hoping to contribute more. Should I also remove `renderErrorToHTML` and `renderError`? #14737
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
-
由 Joe Haddad 提交于
Fixes #16131
-
- 12 8月, 2020 4 次提交
-
-
由 Tim Neutkens 提交于
We no longer use tslint so these comments don't do anything.
-
由 khasty720 提交于
## Summary This PR adds a Next.js example using [Reactsrap](https://reactstrap.github.io/)
-
由 JJ Kasper 提交于
Closes: https://github.com/vercel/next.js/issues/16088
-
webpack://_N_E/由 Andrew Nagy 提交于
In with-sentry add stripPrefix of `webpack://_N_E/`. This removes the `webpack://_N_E/` prefix from the stack trace which will help Sentry to understand what is "App Only" vs "Full" I'll fully tested calling errors in browser and the stack traces are still aligned and linked correctly. This just gets rid of the extra data in the front which seems to be the same for everyone and I believe it comes from webpack 5 (?)
-