You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Prince called directly with the first argument - waits for stdin and passes back to stdout when - is passed to -o
ex. cat test.html | prince - -o -
Unfortunately, I have a need to be able to run Prince on lambda and having file I/O was some overhead that I needed to eliminate.
Following this example on how to run Prince on Lambda. I was able to write my own JS that handles this for my use case.
That being said I really like the API surface you provide here in this library and was hoping you could add something to address this. Whether that be a special chain able method or a modification to Prince.prototype.inputs and/or Prince.prototype.output
The text was updated successfully, but these errors were encountered:
PaulSearcy
changed the title
Feature request: Allow passing inputs as stdin to Prince
Feature request: Implement using stdin and stdout with Prince
Jan 20, 2023
Well you can use control protocol to do that. You can create a child_process (spawn) passing -control as arguments. Now you can pipe stdin and stdout of child_process to any buffer or stream both in input or output
Thank you for writing this wrapper around Prince! It helped speed up my understanding of how to call Prince via a child process.
https://www.princexml.com/doc/command-line/#specifying-input-and-output
Prince called directly with the first argument
-
waits forstdin
and passes back tostdout
when-
is passed to-o
ex.
cat test.html | prince - -o -
Unfortunately, I have a need to be able to run Prince on lambda and having file I/O was some overhead that I needed to eliminate.
Following this example on how to run Prince on Lambda. I was able to write my own JS that handles this for my use case.
That being said I really like the API surface you provide here in this library and was hoping you could add something to address this. Whether that be a special chain able method or a modification to
Prince.prototype.inputs
and/orPrince.prototype.output
The text was updated successfully, but these errors were encountered: