Tutorials and lessons learned from my work as a software developer
Recently, I ran into the problem that my image heavy website, patagoniaonabudget.com, was loading extremely slowly. In this post, I outline the steps I took to go from a 6 second load time to under 2 seconds, specifically focusing on image rendering.
In this post, I'm going to walk through how to make a Facebook Messenger chat bot using my open source Survey Bot Repository. By the end of this tutorial, you'll have a fully functioning bot that responds to a series of questions and saves the information to a database
One of the most powerful functionalities in Laravel is the event. This feature enables all the triggers of various tangentially related functionality to occur throughout the life cycle of a model instance. Plus, events are always listening – meaning you don’t have to explicitly call them in the code to harness their powers. In this post, we’ll implement a sample Laravel model event listener.
Whenever working with data using Laravel, it can be easy to write a few small Eloquent queries within your blade files to access the database. However, this practice can quickly spiral out of control if you're not careful, increasing query load time and destroying the performance of your application. In this post, I'll explain how to extract commonly used queries to a view composer so that they can be shared across multiple views that use different blade files.
Often times when developing using Laravel, I end up stuck on an error that seems to obfuscate the real problem with my code. Luckily, there is a simple way to tail logs in Laravel that can help you get back on track!
In this post, I'm going to walk through a small code sample that automates unit testing for a sort functionality. We will call a JSON API URL, and then test that the information received is properly sorted. We'll also make the tests completely dynamic, enabling us to test multiple parameters to sort on.
Check out My Projects for more
Writing is a way of clarifying my thinking and putting my curiosity on steroids. I spent a year and a half traveling in Asia and South America. This is where I went, what I saw and how it felt, raw and unfiltered:
As our jeep rattled on through the plains, our tour guide stopped intermittently to point out plenty of animals which our eyes glossed over and he was able to spot. Jackals moved swiftly in the distance and herds of deer were spooked by oncoming cars. Monkeys rustled in the treetops, taking a break from their morning snacking to spy on us.
Paraty is undoubtedly paradise. Stefje and I made it our mission to see as much of the islands and beaches that surround this amazing locale, so we hooked up with some other members of the hostel for a boat tour through the bay. In the distance the overgrown islands demonstrated the area’s spectacular propensity for life. Year round sunshine and winter rains ensure that nature dominates here, sprouting up thick forests, fruit trees, and palm branches spreading shade over every square inch of land.
As we continued down the stairs to the overlooking balconies, it immediately became clear why glaciers like this one are capable of retreating or advancing up to two meters in a single day: in the peaceful morning light birds chirping were continuously interrupted by the intense sound of ice calving off and falling into the lake from a height of 40 or 50 yards high. The constant threat of spying one of these awesome breaks had us swinging our necks back and forth along the front wall, which is an astounding 3 miles long and an average height of 240 feet!
Once we reached the trail’s highest point I kept my eyes fixed firmly on the horizon, knowing what was in store ahead. Soon enough, I got my first glimpse of the monstrosity known as Glacier Grey. One of the park’s centerpieces, the massive chunk of ice spans across the entire width of the lake and farther back than the eye can see, steadily rising in height. At the front precipice is a sheer vertical wall of ice, at risk of calving off and sending great chunks into the abyss at any time.
After trying yet failing to break the land speed record, we bussed to a turnoff point for a dirt path. Here was where the real fun began. For the next two hours we bumped downhill, losing feeling in our hands and arms from the intensity of rolling over rocks at such a high velocity. On our left the entire time lay vertical drop offs, some hundreds of meters to the bottom. Despite the initial trepidation of knowing that one wrong move could be our last, we started getting more comfortable and accelerating into the steep turns. Soon we were gaining speed with reckless abandon, all the while trying to sneak glances at the mountainous scenery.
The visual reward upon making it to the top of the Union Pass at 4750 meters made every thigh-busting step worth it. Almost the entire 360 degree view included the glacier-topped peaks that give the Cordillera Blanca its name. The ridge line adjoining the two summits stretched for kilometers in both directions, adorned by snow drifts that appeared ready to plunge into the laguna just below. As I waited for the rest of the group to reach the summit I jumped along the ridge line to enjoy the various vantage points, yelling down in encouragement the calling card for the Cordillera that one of the group members, Paul, had taught us the previous day: “Todo es posible….nada es seguro” ("Anything is possible…nothing is safe").
The boat ride into basecamp seemed more like going to a zoo in a boat or going on a ride at Disney Animal Kingdom. One thing is for sure: it felt completely surreal. As the rain began to lighten intermittently, Romula began stopping the boat every few minutes, pointing out no less than four different species of monkeys, toucans, bats, owls, and even an adolescent Anaconda.
After much deliberation, the girls decided it would be infinitely more fun to jet off with us than to try and take bus trips to the surrounding caves and sights, so the six of us set off on the open road by following the shop owner’s directions: “Go straight. Then straight. Then straight again.”
Last Thursday, I woke up early and had my first encounter with food poisoning in Asia, then conveniently boarded a bus through the windiest road in Thailand, turning 762 times over 151 Kilometers on the way up to the tiny town of Pai in the mountains. As the minivan wound it’s way through the mountains, we were greeted by impressive vistas and misty clouds around almost every turn.
After spending three months in the wonderful landscapes of Patagonia spending a paltry average of $30 a day, I decided to write a book about how I made this a reality, in hopes that I would open up such an adventure to other like-minded travelers. Patagonia On A Budget is available to purchase on Amazon.
Traveling in Patagonia doesn't have to be as expensive as packaged tour operators, TripAdvisor and Lonely Planet might make you believe. With Patagonia On A Budget, you'll learn:
The best value on the craziest adventures
Prices and details for accommodation, transportation and activities in every destination
Detailed maps and itineraries of the most popular backpacking routes
Recommended campgrounds with the best rates and facilities
Instructions and safety advice for hitchhiking
The electronics, websites, and applications to depend on during your expedition
Special instructions for surviving and thriving during long hikes through national parks.
Learn more at PatagoniaOnABudget.com