Using a grid in a modal popup.
In some cases, and in particular with the bootstrap modal, you may find that your grid renders smaller than the
available width (or sometimes appears to render not at all. This is believed to be because the bootstrap modal
animates the initial render and the grid renders whilst the modal is still animating - the available space isn't
as expected. You can correct this by calling handleWindowResize
. The animation time seems to be somewhat variable,
so the currently recommended approach is to use $interval, and to call every 500ms for the first 5s after modal opening.
In a sense this is similar to what the auto-resize feature does, but it only does it for a short period after modal opening.
$ctrlFor better performance with the following example, you can choose to load the ui-grid.core.js file instead:
<script src="/release/ui-grid.core.min.js"></script>