Skip to content

Conversation

@petebacondarwin
Copy link
Contributor

@petebacondarwin petebacondarwin commented Dec 16, 2024

See cloudflare/workers-sdk#7442

Summary

Screenshots (optional)

Documentation checklist

  • The documentation style guide has been adhered to.
  • If a larger change - such as adding a new page- an issue has been opened in relation to any incorrect or out of date information that this PR fixes.
  • Files which have changed name or location have been allocated redirects.


:::

When using a framework or a custom pre-build process, some tools need to generate a modified Wrangler configuration alongside the generated code.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
When using a framework or a custom pre-build process, some tools need to generate a modified Wrangler configuration alongside the generated code.
When using a framework or a custom pre-build process, some tools need to generate a new Wrangler configuration alongside the original code.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

In this case we actually want to say alongside generated code. The "generated config" may get stored on disk in the same directory as the "generated/compiled source code".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I attempted to improve that.


### Custom build tool example

A common approach that a build tool might choose to implement is to output code and configuration in a `dist` directory.
Copy link
Contributor

@ToriLindsay ToriLindsay Jan 9, 2025

Choose a reason for hiding this comment

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

Suggested change
A common approach that a build tool might choose to implement is to output code and configuration in a `dist` directory.
For example, a new configuration file may be generated by a custom build tool when creating a `dist` directory.

You may need to rewrite my suggestion if it doesn't make sense. I added this because I didn't quite understand the connection between this and the section above. I know it says "example" in the header, but I think it would also help to lead in by specifically saying that this is an example of when a new configuration file is generated.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated to make it more example-ish


## Generated Wrangler configuration

When using a framework or a custom pre-build process, some tools need to generate a modified Wrangler configuration alongside the generated code.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
When using a framework or a custom pre-build process, some tools need to generate a modified Wrangler configuration alongside the generated code.
When using a framework or a custom pre-build process, some tools need to generate a new Wrangler configuration alongside the original code.

My main suggestion would be to pick consistent language for what you're calling the original file and the new file because you were using a bunch of different terms and I think it could be confusing. In my edits, I went with the "new, generated file" and the "original, user's file", but you can choose something else, as long as it's consistent.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Tidied up

@afaftrad1

This comment was marked as off-topic.

@petebacondarwin petebacondarwin enabled auto-merge (squash) January 10, 2025 15:06
@petebacondarwin petebacondarwin merged commit 5bdbf8c into cloudflare:production Jan 10, 2025
6 checks passed
@petebacondarwin petebacondarwin deleted the pbd/add-docs-for-redirected-wrangler-config branch January 10, 2025 17:50
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.

5 participants