@flatten-js/core
Version:
Javascript library for 2d geometry
20 lines (12 loc) • 656 B
Markdown
This example illustrates usage of flatten-js library in a browser supporting ```script type="module"``` tag.
It works "as is" without transpiling in most of the modern browsers.
Project uses https://unpkg tool to deliver the package from npm as esm module.
Then we can import classes directly from the module.
Move index.html file into browser and see svg graphics created
Does not work in IE.
All credits to the [Turf](https://github.com/Turfjs/turf/blob/master/examples/es-modules/index.html) project,
where the idea of this code was forked.