Skip to content

Installation ​

The Form Kit ships as three packages. Add the ones you need: a server or tool that only reads and checks definitions needs vyuh_form_types alone; an app that fills forms adds vyuh_form_kit; an app that designs them adds vyuh_form_kit_editor.

Requirements

  • Dart SDK 3.13 or higher
  • Flutter 3.47 or higher (for vyuh_form_kit and vyuh_form_kit_editor)

Authenticate with pub.vyuh.tech first

The Form Kit packages is hosted on the private pub.vyuh.tech registry. Before running pub get, register a Bearer token issued by Vyuh Technologies based on your plan.

Run the one-time setup:

dart pub token add https://pub.vyuh.tech

Don't have a token yet? Email [email protected] to request one. For full details (CI, Docker, rotation, troubleshooting), see the Pub Token Setup guide.

Add Dependencies

Add vyuh_form_types, vyuh_form_kit and vyuh_form_kit_editor  to your pubspec.yaml as hosted dependencies:

pubspec.yaml

Then resolve dependencies:

Setup

Packages ​

PackagePurposeDepends on
vyuh_form_typesThe model and engines, pure Dartcdx_formula
vyuh_form_kitFormView and field controlsvyuh_form_types, vyuh_cdx_ui
vyuh_form_kit_editorFormKitEditor and its controllervyuh_form_kit, vyuh_form_types, vyuh_cdx_ui, cdx_formula_field

No code generation and no feature registration are needed.

Formula fields ​

A FormulaFormField names its result type with FormulaType from cdx_formula. If you declare formula fields in code, add it too:

yaml
dependencies:
  cdx_formula:
    hosted: https://pub.vyuh.tech
    version: ^0.2.2

Imports ​

dart
// Model only (pure Dart).
import 'package:vyuh_form_types/vyuh_form_types.dart';

// Fill time. Re-exports vyuh_form_types.
import 'package:vyuh_form_kit/vyuh_form_kit.dart';

// Design time.
import 'package:vyuh_form_kit_editor/vyuh_form_kit_editor.dart';

Name clash with Flutter

vyuh_form_types defines TextFormField, which Flutter's Material library also defines. Hide Flutter's when you import both:

dart
import 'package:flutter/material.dart' hide TextFormField;

Theme ​

The controls draw with vyuh_cdx_ui. Build your theme with createCdxTheme so they pick up CDX tokens. See Styling for the classic and refined looks.

Next steps ​