From cabdf42df81c2d28b33cb9ebf5894e81198e7811 Mon Sep 17 00:00:00 2001 From: Philipp Tanlak Date: Sun, 11 Feb 2024 23:07:12 +0100 Subject: Update README.md --- README.md | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'README.md') diff --git a/README.md b/README.md index 80b21af..737f96a 100644 --- a/README.md +++ b/README.md @@ -136,10 +136,16 @@ Examples: $ flyscrape run example.js --url "http://other.com" # Enable proxy support. - $ flyscrape run example.js --proxy "http://someproxy:8043" + $ flyscrape run example.js --proxies "http://someproxy:8043" # Follow paginated links. $ flyscrape run example.js --depth 5 --follow ".next-button > a" + + # Set the output format to ndjson. + $ flyscrape run example.js --output.format ndjson + + # Write the output to a file. + $ flyscrape run example.js --output.file results.json ``` ## Configuration @@ -198,6 +204,16 @@ export const config = { "Authorization": "Bearer ...", "User-Agent": "Mozilla ...", }, + + // Specify the output options. + output: { + // Specify the output file. (default = stdout) + file: "results.json", + + // Specify the output format. (default = json) + // Options: "json" | "ndjson" + format: "json", + }, }; export function setup() { -- cgit v1.2.3