|
Dear community, I developed an app that calculates the expenses and credits of a user. I want to show this app to a potential employee for an internship. I have some problems: 1 - In the tabview, when adding the first card, the plus button is inaccessible. 2 - The total amount of the card is calculated adding all the transactions. The user, when deleting a transaction, can choose if a transaction can remain in the card total amount or not. So when doing this the computed property recalculates the total showing a visual bug. Do you have better approaches for this? 3 - I need some revision on the MVVM architecture because I wasn't able to move all the properties to the vm file. 4 - General review of the code, is there some bad or "spaghetti" code? If so can you suggest some improvements? The project is on github, it doesn't have a readme because I want to solve the first problem as fast as I can. Link: [https://github.com/andreasara-dev/MoneyManager.git] Thank you all for the review |
|
Sorry for the slow repsonse but there is a quite alot of code. I will try to explain a few of the pionts. You need to document your code so it easier to understand (you can use option+click to get a summary or drill down to the file quickly) 3 - You have groups the files with Model, Views, ViewModels, however (personal) I group them by view eg Start, Card etc with ALL the files that are used in that file so when you working on a view then find them easily! PS could not see any properties that did not have to in the 4 - Had a look at one Add a file I called it
Also add a file called
Now add a file
Now you can use in
By deleting the commented out code it will read easier. I also noticed that the
now you can add this
You could do the same with the button. Just one other thing if you change
then every you used
Sent Pull Request on github of changes if you want to use it |
|
@NigelGee Thank you! It means a lot for me. You're right, without the amount of modifiers I wrote, the code is so much cleaner, readable and maintanable. I accepted the pull request, again thanks for the help. |
SPONSORED Join a FREE crash course for mid/senior iOS devs who want to achieve an expert level of technical and practical skills – it’s the fast track to being a complete senior developer! Hurry up because it'll be available only until February 9th.
Sponsor Hacking with Swift and reach the world's largest Swift community!
This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.
All interactions here are governed by our code of conduct.
Link copied to your pasteboard.