|
1 | | - |
2 | 1 | # vue-survey-builder |
| 2 | +This is a survey builder component for vue.js applications. |
| 3 | + |
| 4 | +### How to install |
| 5 | +You can install the component using `npm i -S vue-survey-builder` |
| 6 | + |
| 7 | +### Steps to use |
| 8 | +*Step 1:* |
| 9 | +Install is using the above command from npm registry |
| 10 | +There are two components, |
| 11 | +1. **SurveyBuilder**: You can use this to build the survey. |
| 12 | +2. **QuestionsView**: You can use this to view the list of questions added. |
| 13 | + |
| 14 | +You can import them using |
| 15 | + |
| 16 | +`import { SurveyBuilder } from 'SurveyBuilder';` |
| 17 | + |
| 18 | +`import { QuestionsView } from 'SurveyBuilder';` |
3 | 19 |
|
4 | | -This is an open-source project, which makes it easy to build custom surveys using vue.js |
| 20 | +*Step 2:* |
| 21 | +We are using [this JSON]() to build any type of question. Depending on the type of question, only few keys are used in the whole JSON. |
5 | 22 |
|
6 | | -### Getting Started |
| 23 | +### Keys of the JSON |
| 24 | +- **id** : This is a unique field, which will be created dynamically for every qiestion. This field is required for all type of questions. |
| 25 | +- **type** : This represents the type of the question. The supported types are mentioned [here](). This field is required for all type of questions. |
| 26 | +- **multiSelect** : This represents whether the question is multi select question or not. This is is `false` by default and will be `true` only for `MULTI_CHOICE` question. |
| 27 | +- **characterLimited** : It represents the limit for characters, the user can enter. This is used for text type of questions. |
| 28 | +- **hasMinMax** : This represents whether the question has any min and max values or not. This will be used by `NUMBER` type of questions only. |
| 29 | +- **allowDecimals** : This represents whether we need to allow the decimals or not. This will be used by `NUMBER` type only. |
| 30 | +- **sequence** : This represents the sequence of the question. This field will be used by all the question types. |
| 31 | +- **minValue** : This represents the min value. This field will be used by `NUMBER` type of questions only. |
| 32 | +- **maxValue** : This represents the max value. This field will be used by `NUMBER` type of questions only. |
| 33 | +- **labels** : This represents the labels for scale type of question. This field is required for scale type only. |
| 34 | +- **dateFormat** : This represents the date format to be shown. This field is required for `DATE` type of questions. |
| 35 | +- **timeFormat** : This represents the date format to be shown. This field is required for `TIME` type of questions. |
| 36 | +- **intervals** : This represents the number of intervals used for `SCALE` type of questions. |
| 37 | +- **textLimit** : This represents the number character limit for `TEXT` type of questions. |
| 38 | +- **units** : This represents the units to be shown. This field will be used for `NUMBER` type of questions. |
| 39 | +- **options** : This represents the options of question. This field is used by `SINGLE_CHOICE` and `MULTI_CHOICE` questions. |
7 | 40 |
|
8 | | -Install the latest version of this component using `npm install vue-survey-builder -S` |
| 41 | +### Supported Question types |
| 42 | +- BOOLEAN |
| 43 | +- SINGLE_CHOICE |
| 44 | +- MULTI_CHOICE |
| 45 | +- SCALE |
| 46 | +- NUMBER |
| 47 | +- TEXT |
| 48 | +- DATE |
| 49 | +- TIME |
9 | 50 |
|
10 | | -If you would like to install a specific version(eg: v0.0.1), you can use `npm install vue-survey-builder@0.0.1 -S` |
| 51 | +### Demo |
| 52 | +You can see the demo [here]() |
11 | 53 |
|
12 | | -### Contributing |
| 54 | +### Demo Source Code |
| 55 | +Please look at the sample code [here]() |
13 | 56 |
|
14 | | -Read [guidelines for contributing](https://help.github.com/articles/setting-guidelines-for-repository-contributors/). |
| 57 | +### Versions |
| 58 | +#### 0.1.0 |
| 59 | +This version is the initial official release of this component. It has all the required functionalities to build the surveys using vue.js |
15 | 60 |
|
| 61 | +### To-Do List |
| 62 | +- Support for rating question |
| 63 | +- Improve JSON |
| 64 | +- Introduce drag and drop |
16 | 65 |
|
17 | | -### Future Goals |
| 66 | +### Contributors |
| 67 | +[Rajeshwar Patlolla](https://github.com/rajeshwarpatlolla) |
18 | 68 |
|
19 | | -- Introducing drag and drop |
20 | | -- Improving the object structure |
| 69 | +### Organisation |
| 70 | +[Fission Labs](http://fissionlabs.com/) |
21 | 71 |
|
22 | | -### License |
23 | | -Read our license [here](https://github.com/FissionHQ/vue-survey-builder/blob/master/LICENSE.md) |
| 72 | +### LICENSE |
| 73 | +Please read it [here]() |
0 commit comments