Leaflet map in a Tab - 2amigos/yii2-leaflet-extension GitHub Wiki
If you want show the leaflet map in a tab you must set a map global var.
Before init the map you must set
$leafLet = new LeafLet(['name' => 'geoMap',....... and then set
$leafLet->setJs("window.leaf_map = geoMap;");
You must set the "id" property as ['label' => 'Map', 'options' => ['id' => 'maptab'],......... and after this, in the Tab configuration you must intercept the "shown" event
'clientEvents' => [ 'shown.bs.tab' => new JsExpression("function( event, ui ) { debugger; if (event.target.hash == '#maptab') leaf_map.invalidateSize(false); }") ]