Skip to content

feat/initialisms-as-words#1737

Open
chaimleib wants to merge 4 commits into
mgechev:masterfrom
chaimleib:feat/initialismsaswords
Open

feat/initialisms-as-words#1737
chaimleib wants to merge 4 commits into
mgechev:masterfrom
chaimleib:feat/initialismsaswords

Conversation

@chaimleib

@chaimleib chaimleib commented May 19, 2026

Copy link
Copy Markdown
Contributor

Closes #1736

Adds to the var-naming rule: initialismsAsWords: A boolean parameter to treat initialisms as normal words for uppercase and lowercase rules. When initialismsAsWords is set to true, the rule forbids names like readJSON, HTTPMethod, ID, etc. and requires names like readJson, HttpMethod, httpMethod, Id, id, etc.

When true, the built-in list of initialisms is ignored. The allowlist and blocklist continue to function, allowing targeted ignores and progressive enforcement of initialism spelling rules. Unlike skipInitialismChecks or the allowlist, this flag will enforce consistent capitalization.

I also added tests, and documentation about what the other options of var-naming do.

@chaimleib
chaimleib force-pushed the feat/initialismsaswords branch from 278c8c7 to 39754a1 Compare May 19, 2026 17:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

var-naming: initialismsAsWords option

1 participant