The Array.prototype.at example is perfect because target only controls syntax, not which runtime methods exist, so TypeScript happily compiles code that crashes on older Safari. Pairing a browserslist config with eslint-plugin-compat catches those method calls at lint time. Deciding the support list first and deriving both the build target and polyfills from it keeps the two from drifting apart.
StackShortlist
Proof Over Promises.
The Array.prototype.at example is perfect because target only controls syntax, not which runtime methods exist, so TypeScript happily compiles code that crashes on older Safari. Pairing a browserslist config with eslint-plugin-compat catches those method calls at lint time. Deciding the support list first and deriving both the build target and polyfills from it keeps the two from drifting apart.