-
Notifications
You must be signed in to change notification settings - Fork 2
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
chore(update Freibetraege for 2024) #1533
Conversation
…ace magic strings and update tests
… actual, current year is
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice work on the functionality with the map! Just left two comments, but nothing blocking.
app/domains/beratungshilfe/vorabcheck/__test__/freibetrag.test.ts
Outdated
Show resolved
Hide resolved
childrenBelow6Allowance: number; | ||
}; | ||
|
||
export const BASE_ALLOWANCE = 572; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question: when do you use SCREAMING_SNAKE_CASE
and when camelCase
for the constants?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SCREAMING_SNAKE_CASE
should be used for top-level or global constants, and camelCase
should be used for scoped constants (imo, happy to entertain other paradigms :))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, to small remarks
Quality Gate passedIssues Measures |
This PR simplifies and updates the Freibetrag for PKH/BerH by simplifying the interfaces, converting magic strings into constants, and moving year-by-year Freibetraege logic to a map for easy updates.