goods-exporter
Advanced tools
Comparing version 0.3.19 to 0.4.1
@@ -565,6 +565,23 @@ interface Product { | ||
interface Brand { | ||
/** | ||
* **ID бренда** | ||
* | ||
* Целое число | ||
*/ | ||
id: number; | ||
/** | ||
* **Название бренда** | ||
*/ | ||
name: string; | ||
/** | ||
* **Ссылка на изображение** | ||
*/ | ||
coverURL?: string; | ||
} | ||
declare abstract class FormatterAbstract { | ||
abstract formatterName: string; | ||
abstract fileExtension: Extension; | ||
abstract format(products: Product[], categories?: Category[], option?: FormatterOptions): Promise<Buffer | string>; | ||
abstract format(products: Product[], categories?: Category[], brands?: Brand[], option?: FormatterOptions): Promise<Buffer | string>; | ||
} | ||
@@ -586,3 +603,3 @@ interface FormatterOptions { | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], options?: FormatterOptions): Promise<string>; | ||
format(products: Product[], categories?: Category[], _?: Brand[], options?: FormatterOptions): Promise<string>; | ||
} | ||
@@ -593,3 +610,3 @@ | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], options?: FormatterOptions): Promise<Buffer>; | ||
format(products: Product[], categories?: Category[], _?: Brand[], options?: FormatterOptions): Promise<Buffer>; | ||
} | ||
@@ -600,3 +617,3 @@ | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], _?: FormatterOptions): Promise<Buffer>; | ||
format(products: Product[], categories?: Category[], _?: Brand[], __?: FormatterOptions): Promise<Buffer>; | ||
} | ||
@@ -607,3 +624,3 @@ | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], _?: FormatterOptions): Promise<string>; | ||
format(products: Product[], categories?: Category[], brands?: Brand[], _?: FormatterOptions): Promise<string>; | ||
} | ||
@@ -614,3 +631,3 @@ | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], _?: FormatterOptions): Promise<Buffer>; | ||
format(products: Product[], categories?: Category[], _?: Brand[], __?: FormatterOptions): Promise<Buffer>; | ||
} | ||
@@ -621,3 +638,3 @@ | ||
fileExtension: Extension; | ||
format(products: Product[], categories?: Category[], _?: FormatterOptions): Promise<string>; | ||
format(products: Product[], categories?: Category[], _?: Brand[], __?: FormatterOptions): Promise<string>; | ||
} | ||
@@ -629,3 +646,5 @@ | ||
private readonly builder; | ||
format(products: Product[], categories?: Category[], options?: FormatterOptions): Promise<string>; | ||
format(products: Product[], categories?: Category[], brands?: Brand[], options?: FormatterOptions): Promise<string>; | ||
private getBrands; | ||
private getCategories; | ||
private getOffers; | ||
@@ -654,5 +673,5 @@ } | ||
setExporter(exporter: Exporter): void; | ||
export(products: Product[], categories?: Category[], option?: FormatterOptions): Promise<Buffer>; | ||
export(products: Product[], categories?: Category[], brands?: Brand[], option?: FormatterOptions): Promise<Buffer>; | ||
} | ||
export { type Category, Currency, type Exporter, Extension, FormatterAbstract, type FormatterOptions, Formatters, GoodsExporter, type IParam, type ISize, type Product, type Transformer, Vat }; | ||
export { type Brand, type Category, Currency, type Exporter, Extension, FormatterAbstract, type FormatterOptions, Formatters, GoodsExporter, type IParam, type ISize, type Product, type Transformer, Vat }; |
@@ -14,3 +14,3 @@ { | ||
"name": "goods-exporter", | ||
"version": "0.3.19", | ||
"version": "0.4.1", | ||
"description": "A versatile JavaScript library for exporting goods data to various formats such as YML, CSV, and Excel. Simplify data export tasks with ease.", | ||
@@ -36,2 +36,3 @@ "main": "./dist/cjs/index.cjs", | ||
"yml", | ||
"json", | ||
"csv", | ||
@@ -38,0 +39,0 @@ "excel", |
@@ -16,3 +16,3 @@ # goods-exporter | ||
- Export goods data to YML, CSV, and Excel formats. | ||
- Export goods data to JSON, YML, CSV, and Excel formats. | ||
- Easily integrate into your JavaScript projects. | ||
@@ -25,2 +25,3 @@ - Compatible with Node.js version 16 and above. | ||
- YML (Yandex Market Language) | ||
- JSON | ||
- CSV | ||
@@ -27,0 +28,0 @@ - Excel |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
193750
1683
97