Checks for dir and file (.js-ext)