🐛(components): add missing button types and keys
Check Deno code / Check Deno code (pull_request) Successful in 40s
Check Deno code / Check Deno code (pull_request) Successful in 40s
Add type="button" to the EditMobility and UploadStudents buttons to prevent default form submission behavior. Include a key prop on Student components in Promotion for stable list rendering.
This commit is contained in:
@@ -22,7 +22,7 @@ export default function Promotion(props: PromotionProps) {
|
||||
<tbody>
|
||||
{props.students
|
||||
.filter((student) => student.promotionId === props.promo.id)
|
||||
.map((student) => <Student student={student} />)}
|
||||
.map((student) => <Student key={student.id} student={student} />)}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user