React-google-maps: InfoBox

Created on 4 Jul 2017  路  3Comments  路  Source: tomchentw/react-google-maps

Hi i'm using ^6.3.0 but when i do:
import InfoBox from 'react-google-maps/lib/addons/InfoBox';
i get a module not found error, I can see InfoBox.js in the node_modules addons folder.

MarkerClusterer however works fine:
import MarkerClusterer from 'react-google-maps/lib/addons/MarkerClusterer';

Any ideas?

Most helpful comment

@lilywang2110168 try this: import {default as InfoBox} from 'react-google-maps/lib/addons/InfoBox'

unless I'm mistaken, the above is literally the same as

import InfoBox from 'react-google-maps/lib/addons/InfoBox'

@PaulieScanlon I'll take a look over the next day or so and see if I can repro

All 3 comments

try this: import {default as InfoBox} from 'react-google-maps/lib/addons/InfoBox'

@lilywang2110168 try this: import {default as InfoBox} from 'react-google-maps/lib/addons/InfoBox'

unless I'm mistaken, the above is literally the same as

import InfoBox from 'react-google-maps/lib/addons/InfoBox'

@PaulieScanlon I'll take a look over the next day or so and see if I can repro

Was this page helpful?
0 / 5 - 0 ratings