BTabs lazy - do not un-mount on deactivate (actual lazy)
See original GitHub issueIs your feature request related to a problem? Please describe…
While using tabs together with lazy, a tab will be mounted once activated, and un-mounted once deactivted.
However I want a tab to be mounted once activated, and stay that way (only be unmounted once parent is also unmounted, as usual).
Describe the solution you’d like
add another property such as lazy-once
Describe alternatives you’ve considered
Creating my own wrapper around tab with my own implementation of lazy, passing all other attributes and events to vue-bootstrap’s tab component.
Additional context
Issue Analytics
- State:
- Created 4 years ago
- Reactions:6
- Comments:11 (5 by maintainers)
Top Results From Across the Web
How to "lazy load" tab navigator screens now ... - Stack Overflow
Thus, you should be able to pass lazy={true} in your TabNavigatorConfig object, and then tabs will not be rendered before they are active....
Read more >Tab components - React-Bootstrap
A function that takes an eventKey and type and returns a unique id for child tab <NavItem> s and <TabPane> s. The function...
Read more >Bottom Tabs Navigator | React Navigation
A simple tab bar on the bottom of the screen that lets you switch between different routes. Routes are lazily initialized -- their...
Read more >Tabs | Components - BootstrapVue
The tabs component is built upon navs and cards internally, and provides full ... Individual <b-tab> components can be lazy loaded via the...
Read more >React-Bootstrap Tabs Component - GeeksforGeeks
unmountOnExit : It is used to unmount the tabs. variant: It is used to define the navigation style. Tab Props: disabled: It is...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It’s not that different from my component, only you’re using
@click
to detect once it’s seen (and also creating the title your self rather than using the property, although I’m not really sure why). While it’s shorter it still has the same “flaw” of my component - it’s in my project.I’m aware I can “bypass” this feature request and do it on my one with a wrapper, but I believe it’s a useful feature.
Personally I’m not even sure why one would want the current lazy behavior - what is a use of a lazy that keeps deactivating/re-mounting? …
Totally in need of this feature right now! - thanks for the workaround even though they’re annoying more complex for my use case - which is where these tabs are dynamically being included in via a b-table’s v-slot:row_details where the table(s) itself is created by a v-for loop - thus the number of b-tables and b-tabs is unknown, so binding becomes a bit of a challenge…
Being able to lazy-load-once would be awesome.
For that matter, it’d be awesome if that could also be done for b-table v-slot:row-details too…