Author API Methods
questionsApp()
Obtains the instance of the Questions API being used.
You would want to use this method so that you can interact with the Widget editor preview panel and adjust settings, such as enabling the validation mode for the Question, for example.
Examples
var questionsApp = authorApp.questionsApp();
console.log(questionsApp);
Arguments
None.
Return value
Type object
Returns the instance of the questionsApp used in the Widget editor preview panel.
Type boolean
Returns false if not available.
Caveats
Many instances of Questions API may be created while previewing and editing Activities and Items. It is recommended to listen to the render:item event to get the most recent Questions API instance.
Related articles
- Questions API questionsApp methods
- The
render:itemevent, which fires after an Item has finished rendering.