Skip to content
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

Docs: Broken formatting on some method signatures #25921

Closed
donmccurdy opened this issue Apr 25, 2023 · 2 comments · Fixed by #26030
Closed

Docs: Broken formatting on some method signatures #25921

donmccurdy opened this issue Apr 25, 2023 · 2 comments · Fixed by #26030

Comments

@donmccurdy
Copy link
Collaborator

donmccurdy commented Apr 25, 2023

Description

Unfortunately, applying Prettier to the HTML documentation has changed the HTML in ways that appear the same on the page, but are not the same for the purposes of the Regular Expressions in page.js. I'm overall in favor of using Prettier, it's a great way to keep the HTML clean, but we may need to adjust page.js to handle these newlines (or, eventually, find another way of formatting our API docs).

Reproduction steps

View any method documentation with a longer signature, like Color.fromBufferAttribute, on the dev branch.

Code

<!-- before -->
<h3>
	[method:this fromBufferAttribute]( [param:BufferAttribute attribute], [param:Integer index] )
</h3>

<!-- after -->
<h3>
	[method:this fromBufferAttribute]( [param:BufferAttribute attribute],
	[param:Integer index] )
</h3>

Live example

n/a

Screenshots

Note the return value (: this) is on the wrong side of the parameter list:

Screenshot 2023-04-24 at 11 06 42 PM

Version

r152dev

Device

Desktop

Browser

Chrome

OS

MacOS

@donmccurdy donmccurdy changed the title Documentation: Broken formatting on some method signatures Docs: Broken formatting on some method signatures Apr 25, 2023
@Mugen87
Copy link
Collaborator

Mugen87 commented Apr 25, 2023

@vinaykulk621 Can you please have a look at this. That was the issue I was referring to in #25799 (comment), btw.

@Mugen87
Copy link
Collaborator

Mugen87 commented Apr 25, 2023

I've quickly fixed hopefully all breakage by just reverting the formatting so we have fixed docs for r152. Ideally, the regex is improved so things like that don't happen anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants