UNPKG

@apistudio/apim-cli

Version:

CLI for API Management Products

42 lines (34 loc) 979 B
export * from "./runtime/wmgw_runtimeinventry.js"; export * from "./api-model-kinds_generated.js" export * from "./api-model-kinds-exports.js" /** * Represents an inventory item */ export interface InventoryItem { id: string; name: string; description?: string; quantity: number; category?: string; } /** * Sample function for inventory package * @param item - Inventory item to process * @returns Processed inventory item */ export function processInventoryItem(item: InventoryItem): InventoryItem { return { ...item, description: item.description || `Default description for ${item.name}` }; } /** * Gets inventory items by category * @param items - List of inventory items * @param category - Category to filter by * @returns Filtered list of inventory items */ export function getItemsByCategory(items: InventoryItem[], category: string): InventoryItem[] { return items.filter(item => item.category === category); } // Made with Bob