I would like to work on autofixing the extensions rule, would you be open for that? Removing the extension is not a problem, but adding one is tricky, because we can't know whether a should be a.js or a/index.js, right? Should the autofix only work one way?
You'd have to check the filesystem, for one. However, for the index case, a probably should remain as a because it doesn't point to a file, it points to a directory (the index.js is implicit).
Thanks! If the import path is unresolved, should I always treat it as valid as far as extensions rule is concerned? Or should I autofix ./foo.js to ./foo, but not the other way around?
I'm asking because I can't know whether ./foo refers to ./foo.js or ./foo/index.js as it's unresolved, that's why I can only autofix ./foo.js to ./foo (in case the option is never).
Or is it best to ignore the extensions rule if it's unresolved?
I think if a path is unresolved, the extensions rule should ignore it, because there's nothing safe for it to do there.