This last sprint was actually very productive. I feel good about it!
We left off with our form buttons working, however our task was to get the submit button functioning. I believe we had created it already, but it didn’t actually do anything quite yet. We were discussing for some time in a group how we wanted this to work, and I think we ended up struggling for a bit to be able to really understand how to approach the problem. Looking back, this likely came from a lack of really understanding how angular is supposed to function on a webpage.
I believe the majority of us in the group came from the background that our program gave us. That means that we’re used to the object oriented structure that languages like Java use. Java, for example, has classes as the main structure of the program, combined with abstracted classes like Interfaces that all other classes can implement. With Angular we’re using Typescript which is also an object oriented language. We’ve mostly been using components for now, which are essentially classes, and we have yet to use services much in our program, which are essentially interfaces.
In order to implement the functionality for the button, I elected to use a service for it. I did use a youtube video to follow along, but only for understanding where to start. Our group knew we probably needed a click event that created another component, but we didn’t entirely understand how we wanted that to work. Using a service essentially bridges the gap between our form component and our dialog component in this case. Also, by using a service, it creates functionality not only the submit button we were working on, but any future buttons we want to implement that work in a similar way. Services have a decorator, “@Injectable”, which works in a very similar way to Java’s “implements” keyword. By injecting services into your components, you allow any component you want to implement the functions and data present in your service.
We also spent some time yesterday, on the last day of the sprint, merging our branch with the master branch. Some funky things are happening with git currently that I’d like to figure out a little bit better. For example, when pulling the master branch, I got much of the other work that people have been doing. That’s okay and it’s expected, however some of the other components were absolutely riddled with bugs (completely separate from code my group had worked on) that were preventing compilation. I had to spend a large amount of time yesterday fixing and working on the errors in order to even compile and get the angular server running locally, which was quite a hassle. After this, I also had to solve several merge conflicts that arose from pushing our changes to the master branch. These issues were largely found in the app.module.ts imports and everything, and also in files like package-lock.json. Once we resolved this issues, everything seemed to be fine (minus the actual styling of the full application), and we wrapped things up.
All that’s left is to finish our group’s powerpoint presentation and then we’re good to go. It’s been a fun semester, we’ve all learned a lot about the agile workflow, angular, git, and more. Capstone complete!