@exenai/questionnaire-builder
TypeScript icon, indicating that this package has built-in type declarations

3.2.18 • Public • Published

Questionnaire Builder

React 16 lib for building/answering a pair of questionnaires.

Published to npm as @exenai/questionnaire-builder

Usage & Demo

Build

  • yarn install
  • yarn build

Run via questionnaire-demo

  • clone @exenai/questionnaire-demo
  • setup yarn link (yarn link from questionnaire-builder; yarn link "@exenai/questionnaire-builder" in root of that project)
  • yarn dev

Data model

At the top level, you have an Array of QuestionSectionModels

    class QuestionSectionModel {
        id: number;
        title: string;
        questions: Array<QuestionModel> = [];
        canCustomize = true;
        canAdd = false;
        canDelete = false;

        constructor() {
            this.title = '';
        }
    }

With each Section having an Array of Questions

    class QuestionModel {
        id: number;
        title: string;
        type: QuestionTypeEnum;
        config?: RadioConfig | SliderConfig | CheckboxConfig;
        criteria: Array<CriteriaModel> = [];
        
        atsFieldMapping?: string;

        constructor() {
            this.title = '';
        }
    }

Publish

  • Update Version
  • npm login (if you're not logged in already 😉)
  • npm publish --dry-run
  • npm publish

Package Sidebar

Install

npm i @exenai/questionnaire-builder

Weekly Downloads

17

Version

3.2.18

License

MIT

Unpacked Size

490 kB

Total Files

231

Last publish

Collaborators

  • alexxxxxxxxxxxxxx