1vank1n
1vank1n
SSolidJS
Created by 1vank1n on 7/4/2023 in #support
Quiz on SolidJS
Hello, everyone! Anybody could help me? I want to render quiz on SolidJS. Initial I've a json-structure with questions and answers. I want to render quiz where user will choose answers in every questions. As result I get a dictionary with {question_id: answers_id[]} and send it to a backend. Maybe someone have some minutes and could help with my code? I can call via discord and share my screen.
{
"id": 3,
"questions": [
{
"id": 1,
"text": "Первый вопрос",
"image": null,
"answers": [
{
"id": 1,
"text": "Ответ 1",
"image": null
},
{
"id": 2,
"text": "Ответ два",
"image": null
}
]
},
{
"id": 2,
"text": "А тут и второй вопрос",
"image": null,
"answers": [
{
"id": 3,
"text": "Ну",
"image": null
},
{
"id": 4,
"text": "Так се",
"image": null
},
{
"id": 5,
"text": "А тут и третий ответ",
"image": null
}
]
}
],
"created": "2023-05-03T19:30:41.850006+03:00"
}
{
"id": 3,
"questions": [
{
"id": 1,
"text": "Первый вопрос",
"image": null,
"answers": [
{
"id": 1,
"text": "Ответ 1",
"image": null
},
{
"id": 2,
"text": "Ответ два",
"image": null
}
]
},
{
"id": 2,
"text": "А тут и второй вопрос",
"image": null,
"answers": [
{
"id": 3,
"text": "Ну",
"image": null
},
{
"id": 4,
"text": "Так се",
"image": null
},
{
"id": 5,
"text": "А тут и третий ответ",
"image": null
}
]
}
],
"created": "2023-05-03T19:30:41.850006+03:00"
}
Created repository with current state of project — https://github.com/1vank1n/solidjs-quiz
2 replies