✅ This rule is part of the recommended config.
🔧💡 This rule is auto-fixable and provides suggestions.
This rule only auto-fix encoding in fs.readFile()
and fs.readFileSync()
.
await fs.readFile(file, 'UTF-8');
await fs.readFile(file, 'ASCII');
const string = buffer.toString('utf-8');
await fs.readFile(file, 'utf8');
await fs.readFile(file, 'ascii');
const string = buffer.toString('utf8');