美文网首页
Output into file

Output into file

作者: RoyTien | 来源:发表于2017-07-05 11:59 被阅读9次
    (function() {
      fs = require("fs");
      path = 'file.txt';
    
      casper = require('casper').create({});
    
      casper.start(URL, function() {
        fs.write(path, object, 'a');
        fs.write(path, "\n", 'a');
      });
      casper.run(function() {
        this.echo(Date.now()-start + "ms");
        this.echo("Finished running ...");
        return this.exit();
      });
    }).call(this);
    

    相关文章

      网友评论

          本文标题:Output into file

          本文链接:https://www.haomeiwen.com/subject/phxqhxtx.html