Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update docs for nodejs_compat default enable date #17043

Merged
merged 3 commits into from
Sep 26, 2024

Conversation

irvinebroque
Copy link
Contributor

Simplifies docs to direct people to use nodejs_compat rather than nodejs_compat_v2. Tries to reiterate the need to set your compatibility date multiple times, since this is an important detail to follow that could otherwise be missed.

Simplifies docs to direct people to use `nodejs_compat` rather than `nodejs_compat_v2`. Tries to reiterate the need to set your compatibility date multiple times, since this is an important detail to follow that could otherwise be missed.
Copy link

cloudflare-workers-and-pages bot commented Sep 24, 2024

Deploying cloudflare-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 5e1b979
Status: ✅  Deploy successful!
Preview URL: https://61d85bad.cloudflare-docs-7ou.pages.dev
Branch Preview URL: https://bib-nodejs-compat-simpler.cloudflare-docs-7ou.pages.dev

View logs

Copy link

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>
Copy link
Contributor

@petebacondarwin petebacondarwin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we dropping docs around Pages nodejs compatibility?

```

:::note
Starting on September 23rd, 2024, when your compatibility date is on or after `2024-09-23`, the `nodejs_compat` compatibility flag will enable the exact same behavior as `nodejs_compat_v2`.
As of September 23rd, 2024, the `nodejs_compat` compatibility flag enables the exact same behavior as the `nodejs_compat_v2` compatibility flag, as long as your compatibility date is set to September 23rd, 2024 or later.
Copy link
Contributor

@mikenomitch mikenomitch Sep 24, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you think we should explicitly say that you can move back the compatibility date before 9-23 to get the old behavior? Obviously not something we want to encourage broadly, but if somebody runs into a bug with V2 that's not on V1 then it could give them a workaround.

compatibility_flags = [ "nodejs_compat_v2" ]
```

## Enable Node.js in Pages Functions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This all still seems relevant. Why drop it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works the same way as Workers? Set flag in wrangler.toml.

compatibility_flags = [ "nodejs_compat_v2" ]
```

## Enable Node.js in Pages Functions
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works the same way as Workers? Set flag in wrangler.toml.

src/content/docs/workers/runtime-apis/nodejs/index.mdx Outdated Show resolved Hide resolved
@irvinebroque irvinebroque merged commit 8a4534a into production Sep 26, 2024
14 checks passed
@irvinebroque irvinebroque deleted the bib/nodejs_compat_simpler branch September 26, 2024 13:57
patriciasantaana pushed a commit that referenced this pull request Sep 26, 2024
* Update docs for nodejs_compat default enable date

Simplifies docs to direct people to use `nodejs_compat` rather than `nodejs_compat_v2`. Tries to reiterate the need to set your compatibility date multiple times, since this is an important detail to follow that could otherwise be missed.

* Apply suggestions from code review

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>

* Update src/content/docs/workers/runtime-apis/nodejs/index.mdx

---------

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>
elithrar pushed a commit that referenced this pull request Oct 15, 2024
* Update docs for nodejs_compat default enable date

Simplifies docs to direct people to use `nodejs_compat` rather than `nodejs_compat_v2`. Tries to reiterate the need to set your compatibility date multiple times, since this is an important detail to follow that could otherwise be missed.

* Apply suggestions from code review

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>

* Update src/content/docs/workers/runtime-apis/nodejs/index.mdx

---------

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>
maheshwarip pushed a commit that referenced this pull request Dec 2, 2024
* Update docs for nodejs_compat default enable date

Simplifies docs to direct people to use `nodejs_compat` rather than `nodejs_compat_v2`. Tries to reiterate the need to set your compatibility date multiple times, since this is an important detail to follow that could otherwise be missed.

* Apply suggestions from code review

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>

* Update src/content/docs/workers/runtime-apis/nodejs/index.mdx

---------

Co-authored-by: ToriLindsay <tgalatro@cloudflare.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
product:workers Related to Workers product size/s
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants