Gear & Equipment

Books

Access every collectible book in Dinkum, with every place it can be acquired and its buy/sell prices.


Type

Book

FieldTypeDescription
idstringStable identifier
namestringDisplay name
imgstringPath to the book's icon, relative to images/
detailsBookDetail[]Every acquisition source for this book

BookDetail

FieldTypeDescription
aquiredFromstringWhere this copy is obtained
requirementsstringRequirement to obtain it from this source
buyingPricenumber | 'Gift'Purchase price, or 'Gift' if it can only be received as a gift
sellingPricenumberSell price in Dinks

Factory

import { books } from 'dinkum-data'

books() // all 6 books
books(source) // wrap a pre-filtered array

Books have no filter or sort methods, only the standard terminal methods below.


Terminal methods

MethodReturnsDescription
.get()Book[]All results
.first()Book | undefinedFirst result
.find(id)Book | undefinedFind by id
.findByName(name)Book | undefinedCase-insensitive exact name match
.search(query)Book[]Case-insensitive partial name match
.count()numberNumber of results

Examples

import { books } from 'dinkum-data'

books().get()
books().findByName("Adventurer's Journal")

Next steps

  • See Cassettes for another small collectible module
  • Browse Equipment for placeable and wearable equipment
  • Read the core concepts page for how the QueryBase terminal methods work
Previous
Equipment