Fix: allow extensionless js files to be read using the cli (fixes #1131)

Fixes #1131.
I think we still need to check non-js files against ignore paths for consistency.