feat!: allow JSDoc tags without explicit value (e.g. @deprecated
) to default to true
#1172
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1012
As it is mentioned in the issue, currently a tag without explicit value defaults to an empty string. For example,
@deprecated
results in:"deprecated": ""
.What if tags without value would default to
true
instead? On surface this feels like right pattern which reflects actual usage. For instance, this generator has own@nullable
tag, which is assumed to be@nullable true
. Similarly TypeScript has@deprecated
,@internal
.Also I added tests for
@readOnly
,@writeOnly
, which could work in the same way.Just an idea. Could anything get broken?
Version
Published prerelease version:
v0.98.1-next.4
Changelog
馃帀 This release contains work from new contributors! 馃帀
Thanks for all your work!
鉂わ笍 Tom Mrazauskas (@mrazauskas)
鉂わ笍 Jason Dent (@Jason3S)
鉂わ笍 Remi Cattiau (@loopingz)
鉂わ笍 Hadrien Milano (@hmil)
馃殌 Enhancement
as
#1174 (@Jason3S)馃悰 Bug Fix
@deprecated
) to default totrue
#1172 (@mrazauskas)馃敥 Dependency Updates
Authors: 5