Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

draw:created not firing when moving to production #46

Open
AntMam opened this issue Jan 25, 2023 · 0 comments
Open

draw:created not firing when moving to production #46

AntMam opened this issue Jan 25, 2023 · 0 comments

Comments

@AntMam
Copy link

AntMam commented Jan 25, 2023

I've been having trouble getting drawn polygon's geojson in production. When I run the app locally, draw:created fires and I can see the geojson in my requests. Here's the code:

const map = this.$refs.map.$refs.map;

map.mapObject.on("draw:created", (e) => {
      this.searchPolygon = e.layer.toGeoJSON();
    });
map.mapObject.on("draw:deleted", (e) => {
      this.searchPolygon = {};
    });

However, for some reason when running it in production, no geojson makes it into 'searchPolygon' after drawing a shape on the map. I'm running the same Docker image of my frontend locally and in production. I can see the mapObject in both environments too, I've run out of ideas of where to look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant