I am doing a tutorial, and there is some code there that i am not sure i understand:
const Numbers = (props) => {
return (
<div className="card text-center innline">
{ Numbers.list.map((number, i) =>
<span key={i}>{number}</span>
)}
</div>
);
};
Numbers.list = _.range(1,10);
I understand correctly that a constant can not be modified after creation, but what is the Number.list doing on the last line of the code. Is it adding a list to the Numbers function, or are those to separate objects?