Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我希望 casperjsexit()每次触发某个事件侦听器时:
exit()
casper.on "error", (e, stack) -> console.log(JSON.stringify({'error': e, 'stack': stack})) store_error(request_id, 'internal_error', {}) # casper.exit() # @exit()
然而,这些尝试都不起作用。有没有办法做到这一点?
弄清楚了:
casper.then -> @exit()