Nodejs excluir pasta recursivamente
fs.rmdirSync(dir, { recursive: true });
Wide-eyed Fox
fs.rmdirSync(dir, { recursive: true });