josuerushanika / space-travelers

A web app that pulls from the SpaceX API to allow users to view, book, and join commercial and scientific space travel services. Built with React & Redux.
https://space-travelers-f2ji.onrender.com/
MIT License
1 stars 0 forks source link

[1pt] Switch badges for Missions - Conditional components #6

Open josuerushanika opened 1 year ago

josuerushanika commented 1 year ago

Missions that the user has joined already should show a badge "Active Member" instead of the default "NOT A MEMBER" and a button "Leave Mission" instead of the "Join Mission" button (as per design).

Use the React conditional rendering syntax:

{rocket.reserved && ( 
    // render Cancel Rocket button
)}