One of the benefits of using the open source Leaflet mapping library is the wide variety of available community supported plugins. This simple map uses two great plugins - Leaflet Elevation and Leaflet Ajax. The ajax plugin provides a simple way to load data, while the elevation plugin shows elevation from a GeoJSON file in an interactive chart, added to the map as a Leaflet Control. The GeoJSON file must include coordinates.
The plugin is easy to style using css, which is good because I am not a fan of the default themes. I did notice a bug when using the
imperial: true option. The vertical line coming off the hike path disappears when using this option, but otherwise it works as expected. This is another simple way to show data on a map with minimal effort. The plugin does require the D3 library.