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

Greater use of Constants #16

Open
stellarpower opened this issue Oct 14, 2023 · 1 comment
Open

Greater use of Constants #16

stellarpower opened this issue Oct 14, 2023 · 1 comment

Comments

@stellarpower
Copy link

Hi,

Some nice templates in the app. I'd like to see a greater use of constants, and fewer things as hardcoded literals sprinkled through the template file's functions.

I think e.g. some numeric literals are fine, but I'm looking at the "Department News" template right now - changing the typeface or colour scheme ought to be a one-line change really.

I know it's probably the case that when typesetting, as so much is literal information, it's going to be harder to separate constants than when working with typical source code, but I think it's still important to encourage users to write re-usable code, and follow basic principles to make it easy to change and re-configure their work - because as the old adage goes, anything that you think is constant now, will change at some time in the future! So I think at least basic settings defining the appearance or settings of the template should be at the top using let statements.

Thanks!

@laurmaedje
Copy link
Member

Fair.

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

No branches or pull requests

2 participants