iTowns / itowns

A Three.js-based framework written in Javascript/WebGL for visualizing 3D geospatial data
http://www.itowns-project.org
Other
1.1k stars 297 forks source link

[Requirements] Update web browsers requirements for iTowns #2252

Closed Desplandis closed 8 months ago

Desplandis commented 9 months ago

Description

This PR updates and formalizes the web browser requirements for iTowns. See proposal #2256.

Motivation and Context

We are currently using babel's preset-env plugin to decide which syntax transforms and polyfills are used during the transpilation step. However, we do not set an output target in its configuration which causes

Babel [to] assume you are targeting the oldest browsers possible [...] @babel/preset-env will transform all ES2015-ES2020 code to be ES5 compatible. Source

This PR aims to:

Removing unnecessary polyfills for modules well-supported by our target is the object of the follow-up PR #2248