JSFiddle - React, Tailwind, and code Playground
HTML
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=true"></script>
<button id='toggle'>ストリートビューーーーーーー!</button>
<div id='sv'></div>
CSS
#sv {
display:block;
width:450px;
height:300px;
}
JavaScript
$(document).ready(function() {
var center = new google.maps.LatLng(35.661637,139.66656);
var svOptions = { position: center };
var sv = new google.maps.StreetViewPanorama(document.getElementById('sv'),svOptions);
$('#toggle').click(function() {
$('#sv').toggle("slow");
google.maps.event.trigger(sv, 'resize')
});
});