Skip to content
This repository has been archived by the owner on Aug 3, 2023. It is now read-only.

Audit comments #846

Merged
merged 7 commits into from
Nov 6, 2019
Merged

Conversation

EverlastingBugstopper
Copy link
Contributor

This PR standardizes some comments and fixes up some typos

src/commands/build/wranglerjs/output.rs Outdated Show resolved Hide resolved
@@ -57,7 +57,7 @@ pub fn build(
}
TargetType::Webpack => {
log::info!("Webpack project detected. Publishing...");
// FIXME(sven): shouldn't new
// TODO: (sven) shouldn't new
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@xtuc could you explain this comment?

Copy link
Contributor

Choose a reason for hiding this comment

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

i think this should actually be above ln 62, where we call wranglerjs::Bundle::new but i'm not certain precisely why.

Copy link
Member

Choose a reason for hiding this comment

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

My idea was that each backends (rust, webpack, js) returns a Bundle/WorkerBundle/Worker that contains all the bindinds. The creation of the form (code here), would consume it and build a form regardless of the backend used.

If that was implemented building a new bundle wouln't make sense. However, wranglerjs's bundle doesn't contains any state (only constants) so it's fine.

Feel free to remove the comment tho. We could also inline the constants for now.

@@ -58,6 +58,7 @@ pub fn build(
TargetType::Webpack => {
log::info!("Webpack project detected. Publishing...");
// TODO: (sven) shouldn't new
// see https://github.com/cloudflare/wrangler/pull/846#discussion_r342845421
Copy link
Member

Choose a reason for hiding this comment

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

I think a dedicated issue would be safer and easier to discuss in

@EverlastingBugstopper EverlastingBugstopper merged commit 7b97084 into master Nov 6, 2019
@delete-merged-branch delete-merged-branch bot deleted the avery/fix-comment-formatting branch November 6, 2019 19:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants