Embed app with geolocation

Hello -

I am trying to embed an app and allow geolocation to get the user's location for a custom MapBox component.

However, geolocation only works with directly loading the site in retool, not when loading it as an embedded app.

Is it possible to enable geolocation within an embedded app? How so?

<html>
  <head>
    <title>Territory Records</title>
    <script src="https://cdn.tryretool.com/embed.js"> </script>  
    <style>
      #container {
        position: relative;
        overflow: hidden;
        width: 100vw; 
        height: 100vh;        
        max-width:599px;
        margin: 0 auto;
      }
          </style>
  </head>
  <body>
    <div id='container'></div>

    <script>
          
      var rt = window.retool.RetoolDashboard(document.getElementById('container'), "[embedded public URL]");
      
    </script>
  </body>
</html>

I have tried the solutions here with no results:

@Kabirdas Any thoughts on this one?

@finedesignz It doesn't look like it's currently possible to do this in Retool. I can submit a feature request to make this easier to accomplish, and will follow-up with any updates on it

1 Like