Registry / gaming / popn-db-js

popn-db-js

JSON →
library0.21.1jsnpmunverified

A JavaScript/TypeScript client for querying pop'n music SQLite databases (popn-dbs). The current version is 0.21.1. It provides typed access to chart data for supported datecode versions including Unilab (2024073100), Jam&Fizz (2025092400 with extras), and High Cheers (202605___). Key differentiators: strongly-typed API aligned with specific game versions, supports both ESM imports and CJS require, and offers query filtering (e.g., by folder, level).

npm install popn-db-js
INSTALL
IMPORT
SIG · POPN-DB-JS
P
popn-db-js
gamingjavascriptv0.21.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

HighCheers2605
import { HighCheers2605 } from 'popn-db-js'
const { HighCheers2605 } = require('popn-db-js')
ESM import is preferred; CJS require works via default export containing all named exports.
PopnDb default
import PopnDb from 'popn-db-js'
const PopnDb = require('popn-db-js').default
Default import is an object with all datecode-specific prefixes as properties.
Chart type
import type { Chart } from 'popn-db-js'
Types are exported; use 'import type' for TypeScript type-only imports.

Demonstrates importing a version-specific module, querying charts by folder and level, and inspecting chart properties.

import { HighCheers2605 } from 'popn-db-js' // Sample 5 charts from folder 27, level 45 const charts = HighCheers2605.sampleQueriedCharts({ count: 5, query: 'folder=27,lv=45' }) console.log(charts) // Each chart has id, title, difficulty, level, notes, etc.
Debug
Known issues
breakingVersion 0.21.x: Potential breaking changes in query string syntax compared to earlier 0.x versions.
fix
Review query parameters for your version; use docs from GitHub releases.
affects: >=0.16.0 <0.21.0
gotchaCJS require('popn-db-js') returns a default object with version-specific classes as properties; destructuring named exports does not work directly.
fix
Use require('popn-db-js').HighCheers2605 or use ESM import.
affects: >=0.0.0
deprecatedOlder datecode formats (e.g., 'Unilab2024073100') may be removed in future versions.
fix
Use the latest datecode-specific export like 'HighCheers2605'.
affects: >=0.21.0
gotchaChart data is read-only; mutations on returned objects may not persist or cause unexpected behavior.
fix
Treat chart objects as immutable; copy if modification is needed.
affects: >=0.0.0
gotchaQuery syntax (e.g., 'folder=27,lv=45') relies on a specific format; invalid queries may throw or return empty results without clear error.
fix
Ensure query is formatted as 'key=value' pairs separated by commas, matching available fields.
affects: >=0.0.0
Errors
Common errors & fixes
Cannot find module 'popn-db-js'
Package not installed or incorrect import path.
fix
Run 'npm install popn-db-js' (This package has not been published to npm yet, so use git dependency.)
TypeError: HighCheers2605.sampleQueriedCharts is not a function
Importing incorrectly (e.g., destructuring named exports from CJS require).
fix
Use ESM import: import { HighCheers2605 } from 'popn-db-js'
Error: Invalid query syntax
Query string does not follow expected format (e.g., missing equals or comma).
fix
Ensure query is like 'folder=27,lv=45' with no spaces and correct field names.
Upgrade
Version history
0.21.1latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
23 hits · last 30 days
node
20
Resources
popn-db-js — npm install popn-db-js · libregistry