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

fix(lines-before-block): move start-of-block checking behind off-by-default checkBlockStarts option #1341

Merged

Conversation

JoshuaKGoldberg
Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg commented Nov 26, 2024

Fixes #1296.

Intentionally phrased as a fix rather than a feat because IMO reporting on JSDoc blocks at the beginning of a block by default is a bug. But this does add a feature by way of the new option... 🤷

I don't love the name checkBlockStarts. But I couldn't think of anything better.

Doesn't handle array starts ([\n/** ... */]) because that wasn't requested in any issue. I suppose that could be another option? I propose leaving that as a followup.

@JoshuaKGoldberg JoshuaKGoldberg force-pushed the lines-before-block-check-block-starts branch from 0747a53 to 33401b5 Compare November 26, 2024 01:21
@brettz9 brettz9 merged commit f9b102d into gajus:main Nov 26, 2024
5 checks passed
Copy link

🎉 This issue has been resolved in version 50.6.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@brettz9
Copy link
Collaborator

brettz9 commented Nov 26, 2024

Thanks for the PR! I switched it to a feat change just to be a little safer...

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

Successfully merging this pull request may close these issues.

Options for lines-before-block to ignore the beginning of a class, function or other block
2 participants