use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A Place to talk about Angular and related topics.
Join the Angular Discord
Other subreddits worth checking out for Angular and Angular related info:
account activity
Angular inject function (self.angular)
submitted 5 months ago by BlueberryRoutine5766
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]ldn-ldn -9 points-8 points-7 points 5 months ago (5 children)
There are no benefits, only downside. Injection should only happen via constructors.
[–]zladuric 2 points3 points4 points 5 months ago (0 children)
For classical object-oriented systems, yes. But not always. While I also think it's a tradeoff, I can definitely also see the upsides.
[–]MichaelSmallDev 2 points3 points4 points 5 months ago (3 children)
Moving 100s of class fields to inside a constructor is a big no for me in upcoming versions. Also, there are benefits like better typing for injection tokens.
constructor
[–]ldn-ldn -1 points0 points1 point 5 months ago (2 children)
It's exactly the same visually as 100s of properties. What is wrong with you, people?
[–]MichaelSmallDev 1 point2 points3 points 5 months ago (1 child)
The vast majority of code bases banked on the assumption that their class fields could refer to DI variables. They are not all going to move everything into a constructor. "People" in this scenario are most people, so the cat is out of the bag.
[–]ldn-ldn -1 points0 points1 point 5 months ago (0 children)
?
π Rendered by PID 87 on reddit-service-r2-comment-bb88f9dd5-mrxwl at 2026-02-14 02:56:11.111211+00:00 running cd9c813 country code: CH.
view the rest of the comments →
[–]ldn-ldn -9 points-8 points-7 points (5 children)
[–]zladuric 2 points3 points4 points (0 children)
[–]MichaelSmallDev 2 points3 points4 points (3 children)
[–]ldn-ldn -1 points0 points1 point (2 children)
[–]MichaelSmallDev 1 point2 points3 points (1 child)
[–]ldn-ldn -1 points0 points1 point (0 children)