diff --git a/apps/importer/package.json b/apps/importer/package.json index eae5925a..8986590e 100644 --- a/apps/importer/package.json +++ b/apps/importer/package.json @@ -4,6 +4,22 @@ "private": true, "description": "Open-Core Product Normalization, 3-Tier Entity Matching, AI 10-Group Spec Enricher & Anti-Seeding Review Intelligence Engine for Rate Platform", "main": "dist/index.js", + "types": "dist/index.d.ts", + "exports": { + ".": { + "types": "./dist/index.d.ts", + "import": "./dist/index.js" + }, + "./shopee/arena-spec-syncer": { + "types": "./dist/shopee/arena-spec-syncer.d.ts", + "import": "./dist/shopee/arena-spec-syncer.js" + }, + "./shopee/flagship-seed-data": { + "types": "./dist/shopee/flagship-seed-data.d.ts", + "import": "./dist/shopee/flagship-seed-data.js" + }, + "./package.json": "./package.json" + }, "type": "module", "scripts": { "build": "tsc -p tsconfig.json", diff --git a/apps/importer/src/shopee/flagship-seed-data.ts b/apps/importer/src/shopee/flagship-seed-data.ts index 272b9923..a6d0979d 100644 --- a/apps/importer/src/shopee/flagship-seed-data.ts +++ b/apps/importer/src/shopee/flagship-seed-data.ts @@ -19,8 +19,9 @@ export interface FlagshipDeviceSeed { specifications: ProductSpecifications; key_specs: KeySpecs; expert_rating: number; - expert_review_summary: string; - expert_criteria_scores: { + // Optional: newer 2026 entries ship without an expert write-up yet; the DB columns are nullable. + expert_review_summary?: string; + expert_criteria_scores?: { display: number; performance: number; camera: number; diff --git a/apps/importer/tsconfig.json b/apps/importer/tsconfig.json index 545a7a77..0254fefe 100644 --- a/apps/importer/tsconfig.json +++ b/apps/importer/tsconfig.json @@ -8,7 +8,8 @@ "skipLibCheck": true, "forceConsistentCasingInFileNames": true, "outDir": "./dist", - "rootDir": ".", + "rootDir": "./src", + "declaration": true, "paths": { "*": ["./*"] },