-
Notifications
You must be signed in to change notification settings - Fork 734
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
refactor: simplify and document config.ts
#238
Conversation
🦋 Changeset detectedLatest commit: c1b5be5 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
548ad8f
to
8276ff3
Compare
8276ff3
to
7dc4927
Compare
should the decorators be annotated at the top of the file?
|
b06ed5b
to
e5fa75a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
This PR cleans up the type definition for the configuration object, as well as commenting the hell out of it. There are no duplicate definitions, and I annotated what I could. - `@optional` means providing a value isn't mandatory - `@deprecated` means the field itself isn't necessary _anymore_ in `wrangler.toml` - `@breaking` means the deprecation/optionality is a breaking change from wrangler 1 - `@todo` means there's more work to be done (with details attached) - `@inherited` means the field is copied to all environments I also added a stub for the validation function that will be applied to config objects. In the next PR, I will flesh that function out.
e5fa75a
to
c1b5be5
Compare
This PR cleans up the type definition for the configuration object, as well as commenting the hell out of it. There are no duplicate definitions, and I annotated what I could.
@optional
means providing a value isn't mandatory@deprecated
means the field itself isn't necessary anymore inwrangler.toml
@breaking
means the deprecation/optionality is a breaking change from wrangler 1@todo
means there's more work to be done (with details attached)@inherited
means the field is copied to all environmentsI also added a stub for the validation function that will be applied to config objects. In the next PR, I will flesh that function out.
You should review this with split view, since the unified view doesn't really make sense here.