npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

pd-form-core

v1.0.0

Published

Form builder and schema library

Downloads

3

Readme

pd-form-core provides a strictly typed TypeScript API for describing complex medical questionnaires once and exporting them as portable JSON descriptors ready for deployment in Chula PD projects.
It is the foundation used internally by PDPlus and PDClinic, but is published for clinicians and developers affiliated with the Center of Excellence of Parkinson’s Disease and Related Disorders (https://www.chulapd.org/).


Installation

# with npm
npm install pd-form-core

# or with pnpm
pnpm add pd-form-core

The package is published as pd-form-core on npm. It ships as ESM + CJS, fully tree‑shakeable and has no runtime dependencies beyond those listed in its package.json.


Quick Start

import { FormBuilder, defaultSchema } from "pd-form-core";

const builder = new FormBuilder(defaultSchema);

// Insert a simple text input field
const nameField = builder
  .insertField("Std.TextInput")
  .param.setLabel("Patient Name")
  .param.setPlaceholder("e.g. John Doe");

// Export the immutable JSON descriptor
const descriptor = builder.descriptor();
console.log(JSON.stringify(descriptor, null, 2));

Tip: FormBuilder is fluent—most param mutators return the same chainable handle.


Key Features

| Feature | Why it matters | | --------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | | Type‑safe FormBuilder | Compile‑time assurance that every field, rule & param is valid before JSON export | | Schema‑driven | Separate what a form is (descriptor) from how it’s rendered; ship identical questionnaires to web, mobile, or future engines | | Calculables (rules engine) | Built‑in Condition & Summation classes let you compute hidden fields, branching logic, scores, etc. | | Redux Toolkit & Zustand ready | Editor & Viewer stores already wired—drop into React or React‑Native with minimal glue | | Programmatic vs UI mode | schema.programmatic() toggles behaviour so you can seed default forms or build them interactively | | Deno friendly | // @deno-types hints included; no Node‑specific APIs in core |


Mini API

| Method | Description | | ----------------------------------- | ----------------------------------------------------------------------------------------------------- | | insertField(fieldClass, id?) | Adds a field to section 0 (creates the section if missing). Returns a FieldHandle. | | insertFooter(fieldClass, id?) | Adds a field to the footer section. Returns a FieldHandle. | | descriptor() | Captures the current form definition as an immutable FormDescriptor object ready for serialization. |

For a complete listing of methods (including chainable param and rule helpers), see the FormBuilder guide.
To learn how to build custom schemas, jump to the Extending the Schema section of the guide.


License

© 2025 Soluble Labs Co., Ltd. All rights reserved. Redistribution and use without explicit written permission is prohibited.

pd-form-core is not an FDA‑cleared medical device; it is a developer tool for form specification.


Keywords

parkinsons · questionnaire · form‑builder · typescript · redux · json‑schema