Maps initially load at 543px width evevif set width is 100%. How to correct it?

I had set my maps width to 100%. But maps load initially only upto a width 543px. but when a direction search is done, it automatically turns to 100% width. How to load initially in 100%width?