I just stumbled upon your post and carefully studied your code. I think your code is well structured and organized, from the folder structure to the code itself. The namings are good that not even code documentation is needed. I enjoyed reading your code!
However, I would like to add some further thoughts to it. These are by no means criticism:
In the User class, the member function uuidv4 could be outsourced in order to use it for future use cases
I see you always map the users list in all cases, having a small number it probably doesn't affect the performance, but once 10000 users or more are stored, it might lead to some performance hickups, especially when getting to the limits of the local storage
There are no tests, e.g. there are no unit tests for the controller or the service
Another remark is that the id in the user class gets always re generated, even after reading an existing user from the local storage. So you can't rely on a particular user in this case.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I just stumbled upon your post and carefully studied your code. I think your code is well structured and organized, from the folder structure to the code itself. The namings are good that not even code documentation is needed. I enjoyed reading your code!
However, I would like to add some further thoughts to it. These are by no means criticism:
User
class, the member functionuuidv4
could be outsourced in order to use it for future use casesAnother remark is that the
id
in theuser
class gets always re generated, even after reading an existing user from the local storage. So you can't rely on a particular user in this case.