feat: define validators and use normalize-products step (#12473)
Fixes: FRMW-2965 In this PR we replace/remove the existing step to normalize a CSV file with the newly written CSV normalizer and also we validate the file contents further using a Zod schema. I have duplicated the schema for now. But it is makes sense to re-use the schema for CSV validating and `/admin/products/batch`, then I can keep one source of truth under utils and re-export it. WDYT? **Screenshots of some errors after validating the file strictly**  
This commit is contained in:
@@ -41,6 +41,7 @@
|
||||
"@swc/core": "^1.4.8",
|
||||
"@swc/jest": "^0.2.36",
|
||||
"jest": "^29.7.0",
|
||||
"json-2-csv": "^5.5.9",
|
||||
"typescript": "^5.6.2"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user