Inspiration

The inspiration behind ElevateRoute stemmed from a common frustration: while mapping tools excel at showing routes, they often fall short in providing crucial terrain insights that are vital for activities like cycling, hiking, or even planning an accessible walk. I realized that understanding the elevation profile of a route – the climbs, descents, and overall gradient – is just as important as knowing the distance or estimated time. This gap in readily available, interactive elevation data, especially for varied travel modes, sparked the idea for ElevateRoute. I wanted to empower users to truly visualize their journey and prepare for the challenges and rewards of the terrain ahead.

What it does

ElevateRoute is a comprehensive web application designed to help users plan and visualize routes with detailed elevation profiles. Users can input a start location, end location, and add multiple waypoints to create custom routes.The application then dynamically calculates and displays the route on an interactive 2D map, powered by Google Maps Platform.

Beyond basic navigation, ElevateRoute provides:

  • Interactive Elevation Profile: A dynamic chart that visually represents the terrain along the entire route, allowing users to hover and see specific elevation details at any point.
  • Comprehensive Route Statistics: Key metrics such as total distance, estimated time, elevation gain, elevation loss, maximum elevation, and maximum/average grade are presented clearly, giving users a complete overview of their journey's demands.
  • Travel Mode Flexibility: Users can switch between walking, cycling, and driving modes, with route calculations and elevation data adapting accordingly.
  • Safety & Alerts: The application provides a "Safety Score" and intelligent recommendations based on the route's characteristics and optimal travel times, enhancing user preparedness and well-being.
  • Immersive Views: Explore routes with Google Street View and Satellite View, offering rich visual context and a better understanding of the surroundings.
  • Nearby Places & Photo Opportunities: Identify restaurants, gas stations, cafes, parking, and potential scenic spots along the chosen route, enriching the planning experience.
  • Accessibility Features: I've integrated accessibility considerations to ensure the application is usable and informative for a broader audience.
  • GPX Export & Sharing: Users can download their planned routes as GPX files for use with other navigation devices or share a link to their unique route.

How I built it

ElevateRoute was built as a modern Single Page Application (SPA) using React and TypeScript, bundled with Vite for a fast development experience.

  • Frontend: The user interface is developed with React, utilizing Tailwind CSS for a utility-first styling approach, ensuring a responsive and visually appealing design. The interactive map, Street View, Satellite View, and basic map controls are all implemented using the Google Maps JavaScript API.
  • Google Maps Platform APIs: I extensively leveraged several Google Maps Platform APIs:
    • Directions API: For calculating and rendering routes between multiple points.
    • Elevation API: To retrieve precise elevation data along the route path, which is crucial for generating the detailed elevation profile and calculating statistics like elevation gain and loss[cite: 1].
    • Places API: To identify and display "Nearby Places" (restaurants, cafes, etc.) and "Photo Opportunities" along the route.
  • Charting: I integrated chart.js with react-chartjs-2 to create the interactive and responsive elevation profile chart.
  • Development Tools: ESLint and TypeScript-ESLint were used for code quality and consistency. Vite facilitated rapid development and efficient bundling.
  • Deployment: The frontend is deployed as a static site on Render, demonstrating its high availability and performance.

Challenges I ran into

  • Integrating Multiple Google Maps APIs: A primary challenge was seamlessly integrating the Directions, Elevation, and Places APIs to work in harmony. Ensuring that elevation data accurately corresponded to route segments and that place searches were contextually relevant to the route required careful data synchronization and state management.
  • Performance Optimization for Elevation Data: For longer or more complex routes with many waypoints, fetching and processing a large volume of elevation data could become a performance bottleneck. I focused on optimizing API calls and data rendering to keep the application responsive.
  • Accurate Grade Calculation: Calculating min/max grades reliably required understanding the nuances of elevation changes over varying distances and implementing robust mathematical logic to prevent skewed results, especially with small elevation changes over short segments.
  • Implementing "Safety Score" Logic: Developing the algorithm for the "Safety Score" and generating relevant "Safety Recommendations" was complex. This involved defining criteria for safety based on elevation changes, gradients, and optimal travel times, and translating these into actionable insights.
  • Responsive Design for Complex Visualizations: Ensuring that the interactive map and the elevation chart remained intuitive and functional across various screen sizes (desktop to mobile) while displaying rich data was a significant UI/UX challenge.

Accomplishments that I'm proud of

  • Interactive Elevation Profile: I am particularly proud of the dynamic elevation chart, which provides an intuitive and powerful way for users to understand terrain changes visually.
  • Comprehensive Route Analytics: The detailed route statistics and the innovative "Safety & Alerts" section elevate the application beyond a simple mapping tool, offering genuine value for trip planning.
  • Seamless Google Maps Platform Integration: Successfully integrating multiple, complex Google Maps Platform APIs to create a cohesive and feature-rich experience.
  • User-Centric Design: Prioritizing accessibility features and providing intuitive controls for travel modes and waypoints makes the application highly user-friendly.
  • Performance: Achieving a smooth and responsive user experience even with demanding map and data operations.

What I learned

  • Depth of Google Maps Platform: I gained a deeper understanding of the various Google Maps Platform APIs, particularly the nuances of the Elevations API and how to effectively combine it with the Directions and Places APIs for comprehensive location intelligence.
  • Frontend Performance Optimization: I learned practical techniques for optimizing data fetching, processing, and rendering in a React application to maintain high performance, especially when dealing with large datasets or frequent updates.
  • Algorithmic Thinking for Geospatial Data: Developing the safety scoring and grade calculation features honed my skills in applying algorithms to real-world geospatial data to derive meaningful insights.
  • Importance of Accessibility: The process reinforced the critical importance of building accessible web applications from the ground up, benefiting all users.

What's next for ElevateRoute

ElevateRoute has a clear roadmap for future enhancements:

  • User Accounts & Saved Routes: Implement user authentication to allow users to save, manage, and revisit their planned routes.
  • Customizable Safety Criteria: Allow users to define their own safety thresholds (e.g., maximum preferred grade, minimum safe elevation gain) for personalized recommendations.
  • Advanced AI Integration: Further leverage AI/ML for more sophisticated terrain analysis, predictive insights on route difficulty, and even personalized route suggestions based on user preferences and past activity. This would align perfectly with the AI category of awards.
  • Social Sharing & Community Features: Enable users to share their routes with friends, or even contribute to a community database of popular or scenic routes.
  • Enhanced "Nearby Places" Filters: Implement more granular filtering for nearby places, and integrate more diverse data sources for "Photo Opportunities."
  • Mobile Application: Develop native mobile applications to provide an even more seamless experience on the go.
  • Sustainability Focus: Explore integrating data on eco-friendly routes or suggesting routes that minimize environmental impact, fitting into the Sustainability category.

Built With

Share this project:

Updates