Rule details
We have 3 apis for deleting files and directories:
I prefer to consistently use fs.rm, so that I can easily find out all deleting operations by searching fs.rm in code base.
What type of rule is this?
Warns about a potential problem
Example code
import fs from 'node:fs';
import fs from 'node:fs/promises'; // This rule should support node:fs/promises
// These lines of code are considered problematic.
fs.unlink();
fs.rmdir();
fs.unlinkSync();
fs.rmdirSync();
Participation
Additional comments
No response
Rule details
We have 3 apis for deleting files and directories:
I prefer to consistently use
fs.rm, so that I can easily find out all deleting operations by searchingfs.rmin code base.What type of rule is this?
Warns about a potential problem
Example code
Participation
Additional comments
No response