fs.watch disparó dos veces cuando cambio el archivo visto
fs.watch( 'example.xml', function ( curr, prev ) {
// on file change we can read the new xml
fs.readFile( 'example.xml','utf8', function ( err, data ) {
if ( err ) throw err;
console.dir(data);
console.log('Done');
});
});
SALIDA:
algunos datosHecho X 1algunos datosHecho X 2¿Es mi culpa de uso o ...?