Getting Started

React Setup

Install the Arlinear Quiz package in your project.

npm install @arlinear/quiz-react
import { ArlinearQuiz } from "@arlinear/quiz-react";
import "@arlinear/quiz-react/dist/public/style.css";

Overview of Components

/* Renders Quiz */
<ArlinearQuiz 
    quizKey="ba777045-7033-4701-b17b-da9e90dcd41e"
    primaryKey="emily@school.com" // if empty, this does not save grades
/>

/* Render Quiz & Displays results on quiz submit */
<ArlinearQuizWithResult
    quizKey="ba777045-7033-4701-b17b-da9e90dcd41e"
    onSubmit={ () => {} } // function to run onSubmit
    onTryAgain={ () => {} } // function to run onTryAgain (at the end there is a "Try again button")
/>

Live Example

Last updated