refactor: use browser-compatible csv-parse entry point
Update the `csv-parse` import to use the browser ESM sync version and remove unused `fs` and `path` imports in `loader.ts`.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { parse } from "csv-parse/sync";
|
||||
import { parse } from "csv-parse/browser/esm/sync";
|
||||
import {
|
||||
parseSchema,
|
||||
createValidator,
|
||||
@@ -34,8 +34,6 @@ import {
|
||||
} from "./reference-resolver.js";
|
||||
import { generateTypeDefinition } from "./type-gen.js";
|
||||
import { csvToModule } from "./module-gen.js";
|
||||
import * as fs from "fs";
|
||||
import * as path from "path";
|
||||
import {
|
||||
parseTypeDeclaration,
|
||||
parseReverseReferenceDeclaration,
|
||||
|
||||
Reference in New Issue
Block a user