From: Ardis Lu Date: Thu, 9 Jan 2025 05:16:36 +0000 (-0800) Subject: Specify "transformation function" instead of "logic function" to be clear X-Git-Tag: v0.1.0~138 X-Git-Url: https://git.ardis.lu/?a=commitdiff_plain;h=9f301e4f2c1ef12520978a9a5d4abf9665d0afc4;p=csvio Specify "transformation function" instead of "logic function" to be clear --- diff --git a/examples/ex1.js b/examples/ex1.js index 426671d..77b63e9 100644 --- a/examples/ex1.js +++ b/examples/ex1.js @@ -3,7 +3,7 @@ // Minimal example of a user-defined function to transform a CSV. // // Notes: -// - The header row (first row) of the input CSV is not passed to the logic function, it skips through to the output CSV. +// - The header row (first row) of the input CSV is not passed to the transformation function, it skips through to the output CSV. // - The input to the transformation function is already deserialized to an array, however **each field in the array is a string**. // - Each call to the transformation function passes 1 row of the input CSV. // - The expected output of the transformation function is another array representing 1 row of the output CSV. diff --git a/examples/ex2.js b/examples/ex2.js index 2471092..907f482 100644 --- a/examples/ex2.js +++ b/examples/ex2.js @@ -3,7 +3,7 @@ // Set `includeHeaders: true` to manually handle the header row (first row). // // Notes: -// - The header row is assumed to be the first row in the input CSV, and by default it goes directly to the output (skipping the user-provided logic function). +// - The header row is assumed to be the first row in the input CSV, and by default it goes directly to the output (skipping the user-provided transformation function). // - If your input CSV does not have a header row, set `includeHeaders: true` and process the header row (first row) normally. // - Otherwise, you will need distinct logic to handle the header row vs. data rows. A simple boolean variable is a good way to switch between this logic.