Ā Itās...ALIVE!
Well, almost.
With two weeks of project time down, Iām pretty pleased with the progress Iāve made so far. At this point my project meets all of my initial goals of: scraping Craigslist, finding housing within a certain radius, and calculating the commute time. As I expected the most challenging aspects during week 1 were accessing the Craigslist data in the first place, making sense of it (arrays in arrays in objects in arrays in objects, oh my!), and deciding how to handle potentially outdated data. Fortunately the Google Maps and Distance API were an absolute breeze, thanks to their exceptional documentation and elegant Python wrapper.
The challenge I didnāt expect? Just how much Javascript Iād be writing. Since about 80 percent of my applicationās interaction happens on one page, you can imagine it requires many, many event listeners and AJAX calls. There were all kinds of interesting design & efficiency decisions I had to make as a result. For instance, calculating distance with the Google Distance Matrix is a very resource-intensive task, which makes calculating the distance of 200 points from a given origin impractical and inefficient. Additionally, the user only really needs accessĀ to this information when they click on a particular posting. So in this case it makes much more sense to wait until a map marker has been clicked to make the API call and calculate distance. Afterwards this calculation can be stored along with the rest of the post information via theĀ āfavoritesā page.
By far the most helpful tools for sorting out decisions like these were 1) mapping everything out with a pen and paper and 2) putting myself in the userās shoes. While I am an avid (er, obsessed) Asana user, I found that physically writing things down helped me solve problems more easily and quickly. Additionally, during times when I was at risk of going down a programming wormhole (āmaybe instead of adding this drop-down I should add a completely irrelevant feature that will be SO FUN TO BUILD!ā), grounding myself in how people wouldĀ actuallyĀ use my application kept me focused. The survey data I gathered was invaluable for this. Thank you to you lovely readers who responded!
~~~
Thatās it for now! Up next week: refactoring my Javascript to make it easier to maintain, writing more tests, and adding support for cities beyond the Bay Area.
Stay tuned! Check out other project updates here:
https://github.com/noelledaley/hb-final












