/ShinyWebAppWithFormAndLeafletMap

This repo contains the code to build a webapp for data collection and viewing the map on a leaflet map using R Shiny. The specific webapp that I built is aimed to collect data of sustainability practices of various eateries around the world, in the times of climate change.

Primary LanguageRMIT LicenseMIT

Shiny WebApp With Form & Leaflet Map

This repo contains the code to make a webapp using R Shiny with the following features:

  1. Form that feeds data to google sheets
  2. Use of Google Maps APIs in the form fields (autocomplete, geocoding)
  3. Leaflet to plot data from sheets: + Clusters for larger data + Searching through data + Marker colors by variables
  4. Recaptcha for security

Stepwise building of the webapp has been explained in this blog post.

Steps to get the code running:

  1. If you require any google maps api keys, then make a google maps account and generate the keys and enter them in the required locations in the code.
  2. If you use googlesheets for data entry, then make a .secret folder in the same directory as the app file and then force authentication once for the project to make sure the token is cached there.
  3. If you require recaptcha, then generate your keys (site key and secret key) from https://www.google.com/recaptcha/about/
  4. Generate a google sheet to store the data. (Sample data sheet)
  5. Run the app.
  6. View if the data is being filled correctly.

Additionally, if you would like to contribute data about how sustainable are eateries around you, check the webapp live at http://sustainableeateries.com/

I am also looking for collaborators for this project to work on some more features so do reach out.

Adios! ✨