To pass the modal window the link?

There is a button:
const WeatherPageJumbotronButton=()=> {
return(
 <a className="btn btn-primary btn-lg" role="button">
 Choice country
</a>
)
}

By clicking on it I'm trying to implement a modal window appearing with the following code:
const ModalWindowFromWeatherPageButton=(props)=>{
 const {Weather}=props
 ShowMeCountry const=<section>{Weather.country}</section>;
return(

 <div className="modal" tabIndex="-1" role="dialog">
 <div className="modal-dialog" role="document">
 <div className="modal-content">
 <div className="modal-header">
the <ul>
the <li>{ShowMeCountry}</li>
</ul>
 <button type="button" className="close" data-dismiss="modal" aria-label="Close">
 <span aria-hidden="true">&times;</span>
</button>
</div>
 <div className="modal-body">
the <ul>
<p></li>
</ul>
</div>
 <div className="modal-footer">
 <button type="button" className="btn btn-secondary" data-dismiss="modal">Close</button>
 <button type="button" className="btn btn-primary">Save changes</button>
</div>
</div>
</div>
</div>

)
}


As generally implemented in Reacte the pass-by-reference the other component?
Or is it easier just to create a click to call my modal window?
Confused a little :/
March 23rd 20 at 18:44
2 answers
March 23rd 20 at 18:46
Through #ANKOR
JS code parses the current URL and creates a modal window, if it is not.

But in General, if you need the link, it is better not to do a modal window, IMHO.
I just have an application in which on click of the button, I displays a list of countries by selecting a country,I choose the city. I think through the drop down menu to implement all of this-not too aesthetically pleasing - Alfonso commented on March 23rd 20 at 18:49
Example, where there is no modal window at all:
https://www.apple.com/choose-country-region/

And like anything, no one complains.
So a solution where several transitions from page to page, it rules. At least your problem will disappear by itself. - Leslie_Predovic commented on March 23rd 20 at 18:52
@Leslie_Predovic, Um,well,thank you,well done,however. - Alfonso commented on March 23rd 20 at 18:55
March 23rd 20 at 18:48
Read about what dropdown select. Nice you should use it.
About second question, read about what is client routing. Standard in development is considered the React the react-router.

Find more questions by tags ReactJavaScript