this post was submitted on 04 Feb 2025
37 points (97.4% liked)
Programming
18101 readers
156 users here now
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities [email protected]
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I don't see what's the point of the second one if the syntax highlight, even in the first example, already shows a changed role.
A more realistic solution for the example code would be to setup a linter in the pipeline, and if one letter variables and/or template literals are detected, depending on how nice you are, reject the commit, or send an email requesting the author to be beaten up with a crowbar to the teamlead, and a copy, parsed by chatGPT for formality and politeness, to the HR.
that's not a one letter template literal, that's built in python syntax. it only has combinations of u r and f and no user defined option. f makes it templated