I am trying to use the GMap component that is part of the primereact library, but i keep getting this error :
Unhandled Runtime Error ReferenceError: google is not defined
I am working on a next.js app, here is the simple code i copied/pasted from primerreact library:
import { GMap } from 'primereact/gmap';
const DealershipLocation = () => {
const options = {
center: {lat: 36.890257, lng: 30.707417},
zoom: 12
};
return (
<div>
<GMap options={options} style={{width: '100%', minHeight: '320px'}} />
</div>
)
}
export default DealershipLocation