@prairielearn/csv 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/package.json +11 -6
- package/src/index.ts +2 -2
- package/tsconfig.json +1 -1
package/CHANGELOG.md
ADDED
package/package.json
CHANGED
|
@@ -1,24 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prairielearn/csv",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "https://github.com/PrairieLearn/PrairieLearn.git",
|
|
8
|
+
"directory": "packages/csv"
|
|
9
|
+
},
|
|
5
10
|
"scripts": {
|
|
6
11
|
"build": "tsc",
|
|
7
12
|
"dev": "tsc --watch --preserveWatchOutput",
|
|
8
13
|
"test": "mocha --no-config --require ts-node/register src/*.test.ts"
|
|
9
14
|
},
|
|
10
15
|
"devDependencies": {
|
|
11
|
-
"@prairielearn/tsconfig": "
|
|
16
|
+
"@prairielearn/tsconfig": "^0.0.0",
|
|
12
17
|
"@types/mocha": "^10.0.1",
|
|
13
18
|
"@types/multipipe": "^3.0.1",
|
|
14
|
-
"@types/node": "^18.
|
|
19
|
+
"@types/node": "^18.16.19",
|
|
15
20
|
"mocha": "^10.2.0",
|
|
16
21
|
"ts-node": "^10.9.1",
|
|
17
|
-
"typescript": "^
|
|
22
|
+
"typescript": "^5.1.6"
|
|
18
23
|
},
|
|
19
24
|
"dependencies": {
|
|
20
|
-
"csv-stringify": "^6.
|
|
25
|
+
"csv-stringify": "^6.4.0",
|
|
21
26
|
"multipipe": "^4.0.0",
|
|
22
|
-
"stream-transform": "^3.2.
|
|
27
|
+
"stream-transform": "^3.2.6"
|
|
23
28
|
}
|
|
24
29
|
}
|
package/src/index.ts
CHANGED
|
@@ -14,7 +14,7 @@ export interface StringifyNonblockingOptions extends StringifierOptions {
|
|
|
14
14
|
*/
|
|
15
15
|
export function stringifyNonblocking(
|
|
16
16
|
data: any[],
|
|
17
|
-
options: StringifyNonblockingOptions = {}
|
|
17
|
+
options: StringifyNonblockingOptions = {},
|
|
18
18
|
): Stringifier {
|
|
19
19
|
const { batchSize = 100, ...stringifierOptions } = options;
|
|
20
20
|
const stringifier = new Stringifier(stringifierOptions);
|
|
@@ -54,7 +54,7 @@ interface StringifyOptions<T = any, U = any>
|
|
|
54
54
|
* `node:stream/promises`, which will help ensure that errors are handled properly.
|
|
55
55
|
*/
|
|
56
56
|
export function stringifyStream<T = any, U = any>(
|
|
57
|
-
options: StringifyOptions<T, U> = {}
|
|
57
|
+
options: StringifyOptions<T, U> = {},
|
|
58
58
|
): NodeJS.ReadWriteStream {
|
|
59
59
|
const { transform: _transform, ...stringifierOptions } = options;
|
|
60
60
|
const stringifier = new Stringifier(stringifierOptions);
|
package/tsconfig.json
CHANGED