• 0 Posts
  • 248 Comments
Joined 3 years ago
cake
Cake day: June 22nd, 2023

help-circle












  • If Apex had a “singular” purpose then they wouldn’t have built it as a turing complete generalized programming language.

    And the reason you need namespaces is for basic code organization. Classes organize functional objects with a module of code, namespaces let you’re break code into modules.

    If you have two distinct modules of code, each with their own logger class you suddenly have a confusing naming conflict with both loggers being exposed everywhere (or forced you to rename one).

    So then it forces you to try and name your classes like RenderingLogger or Service_Logger and then you very quickly run into the fact that Apex imposes arbitrary length limits on class names.

    If you’re writing a simple db access script then whatever, it can get the job (worse then other languages but it can). If you’re actually trying to build a proper application like you publish on AppExhange then it’s shortcomings become apparent everywhere.

    Hell it didn’t have a reasonable unit testing framework until a side project from some devs introduced Apex Mockery, and it still sucks compared to Mockito and actual professional testing frameworks.






  • There are two types of languages:

    • Ones people complain about
    • Ones that don’t get used

    JavaScript, especially when using TypeScript, is quite frankly one of the most pleasant development experiences. Yes, there are still footguns here and there due to poor early choices and maintaining decades of backwards compatibility (===, etc), but literally all of them are caught by basic linting.

    Go try using Salesforce’s bastardized version of old Java (Apex) if you want to experience a truly unpleasant language.



  • If you’re a user who grows up using one, and then starts following instructions on how to build one, when are you going to come across the word program?

    It will be app, maybe application, saas software, functions a service, compute as a service etc etc. Hell what most people think of as an “app” is really a collection of applications all working together.