JSFiddle - React, Tailwind, and code Playground
HTML
<div id="a">
Div 1
</div>
<div id="b">
Div 2
</div>
<div id="getLocation">
Hide/show
</div>
JavaScript
$('div').click(function(e){
if ( $(e.target).attr('id') != 'getLocation' ) {
$("#getLocation").toggle();
}
})