-
Notifications
You must be signed in to change notification settings - Fork 936
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Responsive container #323
Comments
classic: I posted an issue/question, then immediately found a solution These settings seem to work: Wrapping the entire
Then, the
|
Going to leave open for now since a lot of issues in this project instruct users to give dimensions in absolute pixel values. Would be interested to hear from a dev on the project re: best practices for responsive layout of this component |
I set the containerElement to a div with 100% width and height. Then wrapped the GoogleMapLoader in a Div and gave it a height: 100vh. This may not work for everyone but so far its worked for me. |
I don't have a good solution either. The only thing I knew is Google Maps API requires the div to have certain dimension instead of leaving it auto. |
Also, 6.0.0 is released on npm beta tag now. We also have a new demo page. Feel free to try it: |
I managed to solve this problem by doing the following
|
Yes the key is putting the px at the end. For me, with recompose, the props were: withProps( props => ({ |
Great job @brandonmp, it's work like a charm for me!! Thanks! |
Thank you so much @devenovil ! It works well! |
Can someone point me to a direction for why is a pixel width and height needed and why percentages can't be used? |
From reading through the issues in this project, it looks like the container has to have a height/width set in
px
.Has anyone figured out how to circumvent that and make this component responsive? I can render it fine w/ fixed height/width, but that's not really tenable for the long-term.
The text was updated successfully, but these errors were encountered: