UNPKG

@jeremyckahn/farmhand

Version:
15 lines (11 loc) 388 B
import { itemType } from '../enums.js' import { isItemAGrownCrop } from './isItemAGrownCrop.js' const FARM_PRODUCT_TYPES: farmhand.itemType[] = [ itemType.CRAFTED_ITEM, itemType.FUEL, itemType.MILK, itemType.ORE, itemType.STONE, ] export const isItemAFarmProduct = (item: farmhand.item): boolean => Boolean(isItemAGrownCrop(item) || FARM_PRODUCT_TYPES.includes(item.type))