Lint file types based on their content.
npm i -D file-type-lint
file-type-lint .
const fileTypeLint = require("file-type-lint");
fileTypeLint({
files: "**/*",
})
.then((result) => {
console.log(result.errored); // If `true` when contain error
console.log(result.errors); // Array of errors
return result;
})
.catch((error) => {
throw error;
});
- Formatters.
- Improve error readability.
- Less sync operation.
- More tests (100% coverage).
- Documentation.
Feel free to push your code if you agree with publishing under the MIT license.