Skip to content

docs: rewrite readme and examples for 1.0 - #5

Merged
devCrossNet merged 3 commits into
mainfrom
docs/readme-examples
Oct 8, 2026
Merged

devCrossNet merged 3 commits into
mainfrom
docs/readme-examples

Conversation

@devCrossNet

@devCrossNet devCrossNet commented Oct 8, 2026 •

Copy link
Copy Markdown
Owner

What is accomplished by your PR?

README

  • New structure: Getting started (questions → navigation → usage → end of flow), Guides, API table
  • New content that was missing before:
    • component types and where the next question comes from
    • options that depend on former answers (nested data shape)
    • navigation output properties (value, active, hasValue, isValid, …)
    • validation and reset of dependent answers
    • skipping questions with NO_VALUE
    • jumping to questions, restoring state
    • defaultValue is not saved automatically
  • Fixed: wrong code samples (nextItemId: {}, onSubmit(value: any) in a JS block), typos, /tree/ link to a file, master link, line-number link to types.ts

Examples

  • Every example README explains what it shows and links data.ts and the spec
  • custom-component-types and extending-data-definition list every override and why
  • New example navigation (categories with and without own question, jumping, changing answers) with 4 tests
  • restore-state moved into its own folder with a README

Fix (separate commit, breaking)

hasValue of a parent navigation item with its own question was true as soon as it had a child, even without any answer. It is now true only when the parent or a child has an answer.

Other

  • Fixed misleading comments about _alwaysPossibleFollowUpQuestionComponents (it checks the component type of the question itself)
  • CONTRIBUTING.md: replaced the outdated next branch with main

Is there something controversial in your PR?

  • The hasValue fix is a breaking change (planned for 1.0).
  • The Twitter link is removed (profile no longer exists).

Checklist

  • Run unit tests to ensure all existing tests are still passing
  • Add new passing unit tests to cover the code introduced by your PR
  • Change documentation for the code introduced by your PR

🤖 Generated with Claude Code

devCrossNet and others added 3 commits October 8, 2026 19:31
A parent navigation item with an own question got hasValue: true as soon
as it had a child, even if no question had an answer. hasValue is now true
only if the parent or one of its children has a value.

Also move the restore-state example into its own folder.

BREAKING CHANGE: hasValue of parent navigation items is false until the
parent or one of its children has an answer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- restructure readme: getting started, guides, api table
- document component types, dependent options, navigation output,
  validation, NO_VALUE, jumping to questions and restoring state
- fix wrong code samples and broken links
- explain every example and link its data and tests
- add navigation example with tests
- fix misleading comments about always possible follow up questions
- replace outdated next branch in contributing guide

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@devCrossNet
devCrossNet merged commit 2471eb0 into main Oct 8, 2026
2 checks passed
@devCrossNet
devCrossNet deleted the docs/readme-examples branch October 8, 2026 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant