function write_text(filename, text) {
let pfh = yield OS.File.open("/tmp/foo", {append: true});
yield pfh.write(text);
yield pfh.flush();
yield pfh.close();
}
I tried without the yield which is the more natural form but that broke: In python i'd do yielded_object.next()
error: scribus-web-slurp: An exception occurred.
TypeError: pfh.write is not a function
resource://jid1-orxy9dnn8jbfeq-at-jetpack/scribus-web-slurp/lib/main.js 28
Traceback (most recent call last):
I know Javascript but it's the Firefox-extensions that are causing problems - are there any tutorials that can walk me through the process or bring me up to scratch?? The MDN documentation is too exhaustive and I don;t know where to start.