@ndianabasi
Senior Backend Engineer, Cavai Advertising. Full-stack Software Developer
I'm a full-stack software software with over 8 years experience in various tech fields including Linux server administration, AWS/Azure/Google Cloud cloud architecture, web designs, and software development.
Currently as Senior Backend Engineer at Cavai Advertising.
Nothing here yet.
I guess you are coming from a Python background. JavaScript doesn't have a Dictionary type and won't need to have dictionaries because that's what Objects were designed for and more. We don't have to impose a feature from another language on a different language. Rather, you try to study that language and maximise its capabilities The Object type is so power in JavaScript with tons of methods available to manipulate it. You can easily transform it objects into arrays then into strings. The object type can also be used for OOP as it can inherit properties from parent objects, define its properties, methods, etc.
The reason why professional developers send emails via the backend isn't that they can't do it on the frontend or they aren't aware of these kinds of hacks. The reason is that you are exposing your SMTP credentials or API keys in your frontend Javascript codes when you do this. It doesn't take an inexperienced hacker anything to place breakpoints in your codes are obtain these credentials even if the codes are obsfucated. This is highly unrecommended and should never be done even in a non-critical application like a blog or portfolio page.