• 0 Posts
  • 100 Comments
Joined 2 years ago
cake
Cake day: June 13th, 2023

help-circle

  • I think this is just a picky optimization.

    The first one runs the constructor to instantiate a new string, then gets its class (which is presumably a static property anyway). The second doesn’t have to run any constructor and just grabs the static class name from the type.

    Maybe there’s more implementation nuance here but it seems like an opinionated rule that has zero effect on performance unless that code is being called thousands of times every second. And even then the compiler probably optimizes them to the same code anyway.















  • A full stack developer is either a back end developer that has no business writing front end code but does it anyway, or they’re a front end developer that has no business writing back end code but does it anyway.

    Or they’re perfectly capable of doing both because they’re at a startup that’s years away from running at scale or having to worry about performance and security.


  • Last week, a vendor sold an item for $10. With tax, that item costs $12. Let’s pretend a 50% markup (which is reasonable for retail but insanely high for groceries):

    • they made $5 profit
    • they recouped $5 for their costs
    • they collected $2 of tax for the government

    Now the government has a GST holiday and there’s no tax. I went to the store and bought the item and it still cost me $12.

    • they made $7 profit
    • they recouped their usual $5 for their costs
    • they collected $0 of tax for the government

    The main thing is that their costs for that item didn’t increase and they’re still selling it at its original ”final” price (because they added the tax amount to the sticker price). That tax savings went straight into profits. It was intended for the consumer to save money but the consumer is spending the same amount and the government isn’t getting anything. That money went somewhere.

    Edit: that assumes that the claim made in the post is true. It’s definitely not going to be true across the board, but doubtless there’s some fuckery afoot in some stores.