Build: Require extensions for ES6 imports, prevent import cycles
commit44ac8c8529173711b66046ae5cfefa5bd4892461
authorMichał Gołębiowski-Owczarek <m.goleb@gmail.com>
Mon, 25 Nov 2019 19:16:53 +0000 (25 20:16 +0100)
committerGitHub <noreply@github.com>
Mon, 25 Nov 2019 19:16:53 +0000 (25 20:16 +0100)
tree5f00fbad19e0374fd79cefdb208ae2b328d9bc8d
parent075320149ae30a5c593c06b2fb015bdf033e0acf
Build: Require extensions for ES6 imports, prevent import cycles

jQuery source is now authored in ECMAScript modules. Native browser support
for them requires full file names including extensions. Rollup works even
if import paths don't specify extensions, though, so one import slipped
through without such an extension, breaking native browser import of
src/jquery.js.

A new ESLint rule using eslint-plugin-import prevents us from regressing
on that front.

Also, eslint-plugin-import's no-cycle rule is used to avoid import cycles.

Closes gh-4544
Ref gh-4541
Ref 075320149ae30a5c593c06b2fb015bdf033e0acf
package.json
src/.eslintrc.json