Thanks solve for it, and I have another problem.
The second ${tickettype} come from props
const tickettype = location.state.tickettype;
[`${tickettype}`]: `${tickettype} + ${ticketnumber}`
But ${tickettype} is showing a data like that : "ticketadcopy" At the base ticketadcopy is a constant called in usestate from the firebase database
const [tadcopy, setTAdcopy] = useState('');
const [tvideos, setTVideos] = useState('');
const [tdescriptions, setTDescriptions] = useState('');
const [tthumbnails, setTThumbnails] = useState('');
For the moment, the function arrives in my database as "the value of the props ${tickettype} + a number from ${ticketnumber},
What I would like is that since ${tickettype} will return a value of type "ticketvideos", "ticketadcopy".... that it considers ${tickettype} as the constant tadcopy for example and that when I import to firebase, it gives me :
For example tadcopy = 5
and ${ticketnumber} = 3
5 + 3 = 8
For the moment, it shows me "tadcopy + 3
