StudyConfig
The StudyConfig interface is used to define the properties of a study configuration. This is a JSON object with four main components: the StudyMetadata, the UIConfig, the Components, and the Sequence. Below is the general template that should be followed when constructing a Study configuration file.
{
"$schema": "https://raw.githubusercontent.com/revisit-studies/study/v1.0.2/src/parser/StudyConfigSchema.json",
"studyMetadata": {
...
},
"uiConfig": {
...
},
"components": {
...
},
"sequence": {
...
}
}
info
For information about each of the individual pieces of the study configuration file, you can visit the documentation for each one individually.
The $schema
line is used to verify the schema. If you're using VSCode (or other similar IDEs), including this line will allow for autocomplete and helpful suggestions when writing the study configuration.
Properties
Property | Type | Description |
---|---|---|
$schema | string | A required json schema property. This should point to the github link for the version of the schema you would like. The $schema line is used to verify the schema. If you're using VSCode (or other similar IDEs), including this line will allow for autocomplete and helpful suggestions when writing the study configuration. See examples for more information |
baseComponents? | BaseComponents | The base components that are used in the study. These components can be used to template other components. See BaseComponents for more information. |
components | Record <string , IndividualComponent | InheritedComponent > | The components that are used in the study. They must be fully defined here with all properties. Some properties may be inherited from baseComponents. |
sequence | ComponentBlock | The order of the components in the study. This might include some randomness. |
studyMetadata | StudyMetadata | The metadata for the study. This is used to identify the study and version in the data file. |
uiConfig | UIConfig | The UI configuration for the study. This is used to configure the UI of the app. |