plnkr / feedback

Feedback on Plunker
19 stars 11 forks source link

run without result #565

Closed livelyouth closed 2 years ago

livelyouth commented 2 years ago

Describe the bug https://plnkr.co/edit/sQ70DNH1bALEPmUgjBLw?p=preview&preview running with no result

To Reproduce Steps to reproduce the behavior:

  1. for the point in the setview function in the js file, change the content with 4e6, -5e6
  2. for the geojson file, change the content with { 'type': 'FeatureCollection', 'crs': { 'type': 'name', 'properties': { 'name': 'EPSG:3857', }, }, 'features': [ { 'type': 'Feature', 'geometry': { 'type': 'Point', 'coordinates': [0, 0], }, }, { 'type': 'Feature', 'geometry': { 'type': 'LineString', 'coordinates': [ [4e6, -2e6], [8e6, 2e6], ], }, }, { 'type': 'Feature', 'geometry': { 'type': 'LineString', 'coordinates': [ [4e6, 2e6], [8e6, -2e6], ], }, }, { 'type': 'Feature', 'geometry': { 'type': 'Polygon', 'coordinates': [ [ [-5e6, -1e6], [-3e6, -1e6], [-4e6, 1e6], [-5e6, -1e6], ], ], }, }, { 'type': 'Feature', 'geometry': { 'type': 'MultiLineString', 'coordinates': [ [ [-1e6, -7.5e5], [-1e6, 7.5e5], ], [ [1e6, -7.5e5], [1e6, 7.5e5], ], [ [-7.5e5, -1e6], [7.5e5, -1e6], ], [ [-7.5e5, 1e6], [7.5e5, 1e6], ], ], }, }, { 'type': 'Feature', 'geometry': { 'type': 'MultiPolygon', 'coordinates': [ [ [ [-5e6, 6e6], [-3e6, 6e6], [-3e6, 8e6], [-5e6, 8e6], [-5e6, 6e6], ], ], [ [ [-2e6, 6e6], [0, 6e6], [0, 8e6], [-2e6, 8e6], [-2e6, 6e6], ], ], [ [ [1e6, 6e6], [3e6, 6e6], [3e6, 8e6], [1e6, 8e6], [1e6, 6e6], ], ], ], }, }, { 'type': 'Feature', 'geometry': { 'type': 'GeometryCollection', 'geometries': [ { 'type': 'LineString', 'coordinates': [ [-5e6, -5e6], [0, -5e6], ], }, { 'type': 'Point', 'coordinates': [4e6, -5e6], }, { 'type': 'Polygon', 'coordinates': [ [ [1e6, -6e6], [3e6, -6e6], [2e6, -4e6], [1e6, -6e6], ], ], }, ], }, }, ], }
  3. then run without result,why?
ggoodman commented 2 years ago

Hello @livelyouth, for security reasons, Plunker now runs Previews over https. As a result of browser mixed content policies, Plunker is refusing to load the Leaflet assets from http urls.

Unfortunately, Leaflet's CDN doesn't seem to have their TLS certificates correctly configured so switching the asset urls from http:// to https:// changes the error to a certificate error.

You can observe these errors in the browser console.

I've tweaked your example to instead pull the leaflet library from https://unpkg.com which resolves the mixed content errors and instead exposes some error with how you're loading the .geojson file: https://plnkr.co/edit/EOPPvSbo3D0NUbAz