Turfjs / turf-www

turf website
http://turfjs.org/
MIT License
28 stars 26 forks source link

playground in browser console #201

Open pahuta opened 3 months ago

pahuta commented 3 months ago

Previously I can open browser console and turf was exposed as global variable (I guess it was _). Currently it's not available. Please add this feature back.

smallsaucepan commented 3 months ago

Hi @pahuta. This is the repository for the turfjs.org website. Are you saying you used to be able to do this on turfjs.org and can't anymore?

Or do you mean in your own custom app that uses Turf? If this case best raise an issue on the repo for the library https://github.com/Turfjs/turf/issues

pahuta commented 3 months ago

Hi @smallsaucepan , Yes previously I could do it on a website. It was useful. I read Turf API documentation and right away in the console I could try how method work on my data just by copy-paste it. It worked in the same way as it works on lodash (global _ variable).

jcready commented 2 weeks ago

This feature was incredibly useful. Please expose window.turf on turfjs.org like it used to be. Thank you.

Here's a snapshot of the turfjs.org documentation page: https://web.archive.org/web/20240226065055/https://turfjs.org/docs/

If you go there you can open up the browser console and access turf.

jcready commented 2 days ago

This isn't so much a feature request as it is a bug. Pretty much all of the examples in the API documentation don't actually show the result of the executed code (showing the result in a map is not the same). Previously the user looking at the example code could just execute it directly in their browser console to see the result. Now that the user can no longer do that the code in the examples are not all that helpful.