The first thing that I wanted to do today was to make my "rosters" persistent. The rosters are a key aspect to my program, as the whole point of the program is to track players and their progress over the season. For this task I decided to use local storage as I read about it in this tutorial. http://www.openbookproject.
Next I wanted to make my newly persistent rosters appear in an unordered list. As of now I have barely any css so keep in mind this is all pretty bare. I was able to do this fairly easily until I wanted to be able to delete rosters as well. I was having issues here until I realized that I was mutating a copy of my local storage roster object not the object itself. For a fix I just made a setter method that was easy to use.
By the end of today, I have a method to add and delete rosters, with the ability to add members to a current roster as well.
The next couple steps are:
Figure out the right way to switch pages using JavaScript and HTML, as currently I use the show and hide methods, and I am almost positive that this is one of the worst possible ways to do it, but it works for now.
Get the project up on github
Enable editing individual names and deleting individual names in a roster
Begin to add terms and scoring methods
Add styling to the app.
See you tomorrow.
Excellent post, Eric! You have learned *a lot* on day two of your internship. That is what PRIME is supposed to be all about, so I am pleased.
ReplyDeleteYou mention your lack of experience with JavaScript. I had recommended earlier, and would recommend again, an important book to read if you want to get JavaScript right: "JavaScript: The Good Parts" by Douglas Crockford. It is available on Safari. If you visit this page:
http://www.webappdev.gctaa.net/
and click on the link "NVCC Safari Books" you can login with your NVCC credentials. Let me know if that works.