refactor(compiler-cli): add the ability to treat object literals as enums in docs#54487
Closed
crisbeto wants to merge 1 commit intoangular:mainfrom
Closed
refactor(compiler-cli): add the ability to treat object literals as enums in docs#54487crisbeto wants to merge 1 commit intoangular:mainfrom
crisbeto wants to merge 1 commit intoangular:mainfrom
Conversation
…nums in docs We have a couple of cases now (angular#53753 and angular#54414) where we're forced to redefine enums as object literals. These literals aren't rendered in the best way in the docs so these changes introduce a new `object-literal-as-enum` tag that we can use to mark them so they're treated for documentation purposes.
crisbeto
commented
Feb 17, 2024
| import {extractJsDocDescription, extractJsDocTags, extractRawJsDoc} from './jsdoc_extractor'; | ||
|
|
||
| /** Name of the tag indicating that an object literal should be shown as an enum in docs. */ | ||
| const LITERAL_AS_ENUM_TAG = 'object-literal-as-enum'; |
Member
Author
There was a problem hiding this comment.
I was considering whether to make this a bit more generic, e.g. @docs-type enum, but I think that'll needlessly complicate the docs since we'd have to account for it in all AST node types.
Member
|
This PR was merged into the repository by commit 1d14e52. |
alxhub
pushed a commit
that referenced
this pull request
Feb 21, 2024
…nums in docs (#54487) We have a couple of cases now (#53753 and #54414) where we're forced to redefine enums as object literals. These literals aren't rendered in the best way in the docs so these changes introduce a new `object-literal-as-enum` tag that we can use to mark them so they're treated for documentation purposes. PR Close #54487
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
We have a couple of cases now (#53753 and #54414) where we're forced to redefine enums as object literals. These literals aren't rendered in the best way in the docs so these changes introduce a new
object-literal-as-enumtag that we can use to mark them so they're treated for documentation purposes.