From adae09398df92945685bb19a820cb0a80c6f4c14 Mon Sep 17 00:00:00 2001 From: kamadi2000 Date: Wed, 18 Oct 2023 16:10:18 +0530 Subject: [PATCH] questions display in practice quiz page --- webapp/src/components/QuestionComponent.js | 15 +++++----- webapp/src/views/Exam.js | 34 ++++++++++++++++++---- 2 files changed, 36 insertions(+), 13 deletions(-) diff --git a/webapp/src/components/QuestionComponent.js b/webapp/src/components/QuestionComponent.js index 6650839..a251b6a 100644 --- a/webapp/src/components/QuestionComponent.js +++ b/webapp/src/components/QuestionComponent.js @@ -1,15 +1,16 @@ import React from 'react' -function QuestionComponent({id}) { - const mcq = { - ques:"1. What does a circular road sign with a red border and a white center indicate?", - ans:["Yield to oncoming traffic", "No entry","Give way to pedestrians","Speed limit ahead"] - } +function QuestionComponent({id , mcq}) { + // const mcq = { + // ques:"1. What does a circular road sign with a red border and a white center indicate?", + // ans:["Yield to oncoming traffic", "No entry","Give way to pedestrians","Speed limit ahead"] + // } return (
-
{mcq.ques}
+
{mcq.question}
+ {/*
{mcq}
*/}