Commit graph

16323 commits

Author SHA1 Message Date
vercel-release-bot
cbeecba83b v13.4.6-canary.4 2023-06-14 11:21:24 +00:00
Tim Neutkens
dd937bde09
Remove edge functions tracking in dev server (#51122)
## What?

While looking at the CPU profile of booting up Vercel's site I noticed
that we call `getPageStaticInfo` a lot. Looking into this more it turns
out `getPageStaticInfo` is currently called for all routes, `pages` and
`app`, even though the data is only being used to keep track of which
routes are edge functions, however, this is already tracked as part of
the build output so this didn't make sense to me. First I tried
commenting out this entire block and all tests were passing, so I
removed it except for middleware as middleware can provide a `matcher`
which does need to be known before compiling the file as of right now.

After that change a different set of tests started failing, specifically
the one that checks if we warn correctly. Interestingly by fixing
`getPageStaticInfo` being called early and for all routes it also caused
these warnings to no longer trigger as there was a case in the manifest
plugin that called `getPageStaticInfo` with less information. Calling
`getPageStaticInfo` there was not needed either as we call
`getPageStaticInfo` at the beginning of the build for each entrypoint so
we already have the information required, it just had to be passed down
so that the manifest plugin could use it.

For Vercel's site this change improves booting the dev server by over 1
second.

Related to #48748

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

---------

Co-authored-by: Jiachi Liu <inbox@huozhi.im>
2023-06-14 13:17:16 +02:00
vercel-release-bot
c8f65ede87 v13.4.6-canary.3 2023-06-14 06:52:30 +00:00
JJ Kasper
99bdad4274
fix trigger release step 2023-06-13 23:45:54 -07:00
JJ Kasper
aa8400c2ca
Update flakey rsc streaming test (#51274)
This is checking for only alpha-numerical chars for the build_id value
although they can also contain dashes

x-ref:
https://github.com/vercel/next.js/actions/runs/5263773644/jobs/9514284188#step:25:454
2023-06-13 23:37:19 -07:00
John Albin Wilkins
1e796726ee
Document CSS concatenation order matches the import order (#39889)
Given the amount of CSS ordering problems mentioned in the issue queue
(see #16630), it's clear, for most people, that it is NOT obvious that
the order of CSS concatenation matches the order of importing CSS and
modules inside `_app.js`.

We should try to make this fact explicit in the docs. Right now, it's
only implied.


## Documentation checklist

- [x] Make sure the linting passes by running `pnpm lint`
- [x] The examples guidelines are followed from [our contributing
doc](https://github.com/vercel/next.js/blob/canary/contributing.md#adding-examples)

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 23:31:49 -07:00
JJ Kasper
f676d001b6
Correct build workers perf issue (#51271)
This continues off of https://github.com/vercel/next.js/pull/49937 and
https://github.com/vercel/next.js/pull/50194 ensuring we don't regress
on build perf due to reducing the amount of workers being used in
parallel.

Fixes: https://github.com/vercel/next.js/issues/51201
Fixes: https://github.com/vercel/next.js/issues/50555
2023-06-13 23:23:50 -07:00
Brandon Owens
862f556c69
Update Player.tsx to improve code readability and styling. (#50275)
Updated the demo player component to have more consistent styling and
format.

I thought this could be some nice spring cleaning for the community 🧹 

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 23:20:28 -07:00
Lazar Nikolov
2ce15c4d3c
update(examples): Update with-sentry example (#47855)
Updating the `with-sentry` example with latest dependencies versions, new feature docs, and also converted it to TypeScript.

## Documentation / Examples
- [x] Make sure the linting passes by running `pnpm build && pnpm lint`
- [x] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)

Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
2023-06-14 06:10:06 +00:00
Joost De Cock
667a90262b
[docs] Clarify .md handling with @next/mdx (#49785)
…iles as MDX

I got bitten by this passage because it reads as if merely changing the
`extension` setting will cause `.md` files to be loaded as MDX.

See: https://github.com/mdx-js/mdx/issues/2302

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 22:53:04 -07:00
Riqwan Thamir
825eefe7c0
Add mikroORM to external package list (#50487)
### What?

Adds mikroORM to external package list

### Why?

To prevent developers using
[MedusaJS](https://github.com/medusajs/medusa) modules with NextJS from
having to add this in their next config.

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 22:49:50 -07:00
Dustin Thurston
dd61ee44c5
Show how to utilize the provided .env file in the docker-compose file (#50712)
### What?
I added a small change to the `with-docker-compose` example to show how to make the provided `.env` file usable.

### Why?
I struggled to understand why I could not get environment variables to work as intended and thought this small change might help someone else new to docker in the future.

### How?
Added a few comments to the `docker-compose.dev.yml` file, along with showing how to utilize a `.env` file with docker-compose



Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
2023-06-14 05:42:00 +00:00
Akira Kijinami
d080c8ee79
fix deprecated configureStore in with-redux-saga example (#50342)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

This PR introduces the following changes:
- Replaced redux's [deprecated
createStore](https://github.com/reduxjs/redux/pull/4336) with
configureStore from @reduxjs/toolkit.
- Updated packages.
- Corrected an error in getStaticProps.

This is my first contribution and there may be some shortcomings, I
appreciate your understanding and look forward to your feedback.

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 22:00:35 -07:00
Tom
6f9c9ad1d8
fix: cypress component testing - fixes #50283 (#50303)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->
### What?

Fixing the cypress component testing example, since it breaks the
next.js build process.

### Why?

The default example is not working regarding this issue:
https://github.com/vercel/next.js/issues/50283

Because there's a cypress test file (`*.cy.tsx`) inside the `/pages`
directory.

### How?


In this pull request, I made the following changes:

- Removed the new Cypress component test file from the /pages directory
to resolve conflicts with the build process.
- Created a dedicated directory for components, and created a new
example component.
- Moved the test file to the new component directory to ensure it works
as expected.

Build works:


![image](https://github.com/vercel/next.js/assets/987947/f79cc585-ad32-4780-ba56-a5f28259c69c)

Starting the new component testing works:


![image](https://github.com/vercel/next.js/assets/987947/032cff8f-5d1f-4aa2-b6b6-c95b5739e838)

Cypress Component Testing starts correctly:


![image](https://github.com/vercel/next.js/assets/987947/dff446b7-533b-4f6a-8f6c-09066866ba41)

The Component Test is there and ready to test:


![image](https://github.com/vercel/next.js/assets/987947/c235e1bb-9097-47b9-a625-a71b2ef5e129)

The Component Test passed as expected:


![image](https://github.com/vercel/next.js/assets/987947/fbaeaa18-5b63-4de6-9953-486bd7959703)

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 21:53:50 -07:00
Tom
a59c1f0d58
Fix with typescript stripe example fixes #50541 (#50574)
### What?

The TypeScript Stripe example has been fixed to address various issues. One of the issues was related to calling a function, which has now been resolved. Additionally, the Stripe API used in the example was outdated, causing an error during the build process. This issue has also been fixed.

By making these fixes, the TypeScript Stripe example should now work correctly without any function calling issues or errors related to the outdated Stripe API during the build.

### Why?

There's an issue regarding this problem `Fix with typescript stripe example fixes #50541`

```console
$ next build
- info Linting and checking validity of types ..- error ESLint must be installed in order to run during builds: yarn add --dev eslint
- info Linting and checking validity of types ...Failed to compile.

./components/CartSummary.tsx:41:24
Type error: Argument of type '{ sessionId: any; }' is not assignable to parameter of type 'string'.

  39 |     }
  40 |
> 41 |     redirectToCheckout({ sessionId: response.id })
     |                        ^
  42 |   }
  43 |
  44 |   return (
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
```

### How?

- Calling the `redirectToCheckout` function the right way 275cb65f3d/use-shopping-cart/react/index.d.ts (L65)
- Updating Stripe API
- Fix some changed / depcrated code since the API has changed a little
- Fix a TS error since the used library does not has a correct TS defintion file


![image](https://github.com/vercel/next.js/assets/987947/dd21dbb0-e949-4b3e-a26c-6a6d720c6e37)



Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
2023-06-14 04:41:56 +00:00
JJ Kasper
6dcc4fbc23
Increase remote cache timeout for swc builds (#51270)
These occasionally timeout and start building even when they don't need
to so this increases them a bit from the default.
2023-06-13 21:31:40 -07:00
Choi Sumin
8ac9b342e3
chore(router): fix typo in comment (#50581)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->


### What?

fix typo in comment (withRoute -> withRouter)
2023-06-13 21:10:36 -07:00
Baffin Lee
2bd76827f0
Fix build error about trace file and edge route (#50808)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

### What?

Error occurs when processing trace file rules of edge route.

### Why?

Edge routes have no trace files, so we don't need to process exclude and
include rules about it's trace file.

### How?

Fixes https://github.com/vercel/next.js/issues/50791

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 21:04:10 -07:00
Zack Tanner
3427d324d8
fix: app router hash scrolling should respect scroll-padding (#51268)
When navigating to a route with a hash parameter, the layout router
jumps to the element by scrolling to the node's `offsetTop` value.
However, this will ignore `scroll-padding`, which deviates from browser
behavior.

It looks like this isn't an issue in the pages router which currently
makes use of
[`scrollIntoView`](https://github.com/vercel/next.js/blob/canary/packages/next/src/shared/lib/router/router.ts#L2262).

Closes NEXT-1171
Fixes #49612

---------
2023-06-13 20:50:51 -07:00
Baffin Lee
4ef3982f62
chore: remove useless duplicate code (#50705)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

## What?

Remove useless duplicate code in `next-server.ts`, there are exactly the
same code in next lines.

## Why?

That code have no side effect, run it twice won't make any difference,
seems like someone forgot to delete it.


![image](https://github.com/vercel/next.js/assets/17738556/848d4b03-78cd-40a4-ae8b-a3126101efac)

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 20:38:01 -07:00
Ethan Arrowood
d31ced1d26
update storybook example (copy from vercel/vercel) (#50865)
Updates the `with-storybook` example to be the example located in [`vercel/vercel`](https://github.com/vercel/vercel/tree/main/examples/storybook). 

The motivation for this change is that we now have better support for storybook. It is now treated as its own framework and so users can specify the `storybook` framework as well as custom build command `build-storybook` in order to get near zero-config support 🌟 

Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
2023-06-14 03:18:44 +00:00
wiredacorn
cc46d97232
Update module-path-aliases.md (#43592)
<!--
Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change that you're making:
-->

## Bug

- [ ] Related issues linked using `fixes #number`
- [ ] Integration tests added
- [ ] Errors have a helpful link attached, see
[`contributing.md`](https://github.com/vercel/next.js/blob/canary/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`
- [ ]
[e2e](https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
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`](https://github.com/vercel/next.js/blob/canary/contributing.md)

## Documentation / Examples

- [X ] Make sure the linting passes by running `pnpm build && pnpm lint`
- [X ] The "examples guidelines" are followed from [our contributing
doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 19:53:17 -07:00
J
18b133e6a3
docs: fixed a typo in parallel routes (#51267)
`allow` => `allows`
2023-06-14 02:45:48 +00:00
Willem-Jaap
0bda6287b6
fix(cli): add all available options to cli commands, format them consistently (#48708)
### What?
Add all available options to cli commands
Consistent formatting for all options

### Why?
Options were not consistent across all commands, some were missing



Co-authored-by: Steven <229881+styfle@users.noreply.github.com>
Co-authored-by: JJ Kasper <22380829+ijjk@users.noreply.github.com>
2023-06-14 02:36:08 +00:00
Guilleo
691598ecee
Fix middleware documentation (#48876)
In the actual documentation, `value` does not exist. I removed `value`
and work correctly

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation or adding/fixing Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 19:18:11 -07:00
William Wilder
99142b5897
Update 02-fonts.mdx (#51249)
Add link to font api instead of internal reference to same page.

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 19:06:32 -07:00
Joe Marty
ac32452d1c
Clarify the limitations of NEXT_PUBLIC_ (#49105)
It's not totally clear from the docs that using `NEXT_PUBLIC_` env vars
will be a problem for pipelines that deploy the same image to multiple
environments (this bit us in a production incident). This PR is an
attempt to make it clear. Open to feedback/suggestions!

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 19:01:44 -07:00
Jan Cizmar
0a9148901b
docs: Add Tolgee to internationalization section (#49754)
It would be nice to have Tolgee listed in internationalization libs
supporting Next.JS

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 18:50:11 -07:00
Yishay Hazan
fe2c0cbc5d
Update fast-refresh-reload.md (#49953)
Full refresh happens when component's name is camelCase instead of PascalCase
2023-06-14 01:45:27 +00:00
Delba de Oliveira
543dcfec6f
Add leerob as an optional global codeowner (#51257)
Add @leerob as an optional global code owner. This means he won't be
tagged for reviews on every PR, but he can approve PRs. This allows the
@vercel/devex to make changes more quickly, without having to distract
the Next.js team.

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 15:15:55 -07:00
Delba de Oliveira
85ea7cde33
Remove related-links (#51258) 2023-06-13 22:12:48 +00:00
Steven
0f03ef14f0
chore(docs): codemod docs should mention . for cwd (#51264)
These docs were wrong because `./pages` is not sufficient to run a
codemod.

Imagine a project that has `./components` and `./pages` and many
directories for example.

Also its important to run at the root of the Next.js project so that the
path has a `next.config.js` because some codemods modify that config.
2023-06-13 14:44:53 -07:00
Delba de Oliveira
d27a4969f6
Fix code example filename for related-links (#51256) 2023-06-13 13:36:41 -05:00
Michael Novotny
94accfacf1
Adds homepage to eslint-config-next package (#51059)
Fixes (partially) #50843.

---------

Co-authored-by: Steven <steven@ceriously.com>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
2023-06-13 11:22:05 -07:00
Delba de Oliveira
6431b19906
Fix broken link (#51253)
Fix broken link in client-side rendering page
2023-06-13 13:08:19 -05:00
Delba de Oliveira
8a0686e28d
[Docs] Add version history to app api pages (#51218) 2023-06-13 18:03:27 +00:00
Delba de Oliveira
3d41ccb916
Update codeowners (#51250)
Tweak code owners after some testing and feedback. 

- Move the Next.js team up to be optional global code owners (so that everyone can review but are not tagged for review). Global individuals should still be tagged if there are no specific `.vercel.approvers` files in subdirectories.
- Adds @vercel/devex to image files so there's coverage on those files for the docs
- Target specific folder and files for Styfle to get notified
- Deletes some rules in the old GitHub codeowners
2023-06-13 17:47:12 +00:00
Delba de Oliveira
a3344ad6fc
[Docs] Add mininum client-side rendering page (#51220) 2023-06-13 12:16:29 -05:00
Will Binns-Smith
8f4ae065e0
Turbopack: remove __internal_nextjs_integration_test compile-time feature (#51204)
This removes the `__internal_nextjs_integration_test` compile-time feature. This would end up requiring an additional set of build targets for running integration tests was only used for two cases:

* Determining whether to read from an env var to load mocked Google fonts responses in next/font/google tests. This now uses the presence of this variable to determine whether to use mocked responses.
* Enabling the `next-dev/serializable` feature. This is now set directly instead.

Test Plan:
* Integration tests with Turbopack.
* Manual test of next/font/google with Turbopack
2023-06-13 16:26:44 +00:00
Jiachi Liu
6e5169b17a
Add buildId into RSC payload (#50974)
Co-authored-by: Tim Neutkens <tim@timneutkens.nl>
2023-06-13 17:58:07 +02:00
Shu Ding
9ffea84080
Simplify the client manifest structure (#51183)
Both of our bundlers won't split different exports of a module into different chunks, we can rely on https://github.com/facebook/react/pull/26624 to simplify the structure. This reduces the size of the client reference manifest by ~70%.
2023-06-13 15:25:39 +00:00
OJ Kwon
bfbfa872fe
ci(workflow): skip test trace upload when test skips (#51190)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Adding or Updating Examples

- The "examples guidelines" are followed from our contributing doc
https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md
- Make sure the linting passes by running `pnpm build && pnpm lint`. See
https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md



## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change



### Why?

### How?

Closes NEXT-
Fixes #

-->

### What?

Attempt to fix workflow to skip trace upload if test skips.
2023-06-13 08:06:15 -07:00
Delba de Oliveira
e048f4ef03
[Docs] Recommend prettier-fix in PR template and contribution guide (#51237)
Recommend running `prettier-fix` before opening docs PRs to fix formatting issues. I've found that `lint-fix` is currently not fixing formatting issues. Related: https://vercel.slack.com/archives/C03S9JCH2Q5/p1686647582580629
2023-06-13 14:54:06 +00:00
Sora Morimoto
0840793abf
Fix all 404 links (#51209)
I found some 404 links in jsdoc, so I used ripgrep to find and fix all the broken links to fix all the other links in this PR.
2023-06-13 14:25:40 +00:00
VelociRaptor
b89da42985
[docs] Fix typo in parallel routes (#51238) 2023-06-13 13:54:37 +00:00
Delba de Oliveira
a611641cec
[Docs] Remove extra line in summary dropdowns (#51226)
They were causing markdown to render a <p> tag which has margins and broke the summary dropdowns
2023-06-13 13:50:20 +00:00
Chad Luo
2a93345f14
[Docs] fix example function param and signature (#51235)
Apparently the object deconstruction in the example doesn't work. This PR proposes a working version:

```diff
- export default function Page({ params: { slug: string } }) {
-   return <div>My Post: {slug}</div>
- }
+ export default function Page({ params }: { params: { slug: string } }) {
+   return <div>My Post: {params.slug}</div>
+ }
```

According to the [page reference](https://nextjs.org/docs/app/api-reference/file-conventions/page), the page function parameter slugs needs to be retrieved by calling `params.slug`.

The TypeScript section below shows the correct function type signature, although not referencing to the parameter.
2023-06-13 13:33:31 +00:00
vercel-release-bot
b80dc83b23 v13.4.6-canary.2 2023-06-13 13:13:56 +00:00
Kiko Beats
4633b2254b
[docs] Add missing Edge Runtime APIs (#51224)
Added missing APIs, also sorted all of them alphabetically to make it
easier to read.

---------

Co-authored-by: Delba de Oliveira <delbabrown@gmail.com>
2023-06-13 11:01:40 +01:00
Jiachi Liu
d544c2806e
docs: fix prettier lint (#51222)
Fix prettier lint errors in #51080
2023-06-13 09:19:10 +00:00