Access every plantable seed in Dinkum, for crops, trees, and bushes alike, with growth timing and season.
Type
Seed
| Field | Type | Description |
|---|
id | string | Stable identifier |
name | string | Display name |
img | string | Path to the seed's icon, relative to images/ |
source | string[]? | Where the seed is purchased or obtained |
baseSellPrice | number | Base sell price in Dinks |
buyPrice | number? | Purchase price, if purchasable |
category | string | 'Crop Seed', 'Tree Seed', 'Bush Seed', etc. |
growthPeriod | number | Days to reach maturity |
outputCountMin | number? | Minimum yield per harvest |
outputCountMax | number? | Maximum yield per harvest |
regrowth | number? | Days between harvests once mature |
season | Season[] | Seasons the seed can be planted in |
Factory
import { seeds } from 'dinkum-data'
seeds()
seeds(source)
Filters
| Method | Signature | Description |
|---|
byCategory | byCategory(category: string) | Filter by seed category (exact match, case-insensitive). |
bySeason | bySeason(season: Season) | Filter to seeds plantable in the given season. |
import { seeds } from 'dinkum-data'
seeds().byCategory('Tree Seed').get()
seeds().bySeason('Summer').get()
Sorts
| Method | Signature | Default | Description |
|---|
sortByGrowthPeriod | sortByGrowthPeriod(order?: 'asc' | 'desc') | 'asc' | Sort by growth period in days. |
Terminal methods
| Method | Returns | Description |
|---|
.get() | Seed[] | All results |
.first() | Seed | undefined | First result |
.find(id) | Seed | undefined | Find by id |
.findByName(name) | Seed | undefined | Case-insensitive exact name match |
.search(query) | Seed[] | Case-insensitive partial name match |
.count() | number | Number of results |
Examples
import { seeds } from 'dinkum-data'
seeds().bySeason('Summer').sortByGrowthPeriod().get()
seeds().byCategory('Tree Seed').get()
Next steps