proste_indexed_stack
0.2.4, released 5 years ago by an unverified publisher
A lazy‑loading IndexedStack widget for Flutter that loads pages only when first shown.
What it does
ProsteIndexedStack behaves like the standard IndexedStack but creates each child only when it becomes visible for the first time. It also offers an optional preload flag for specific children.
AI-written summary of version 0.2.4, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want to keep multiple pages in memory but avoid building them all at startup
- You need a drop‑in replacement for IndexedStack with lazy loading to improve initial load performance
Skip it when
- All pages must be built immediately
- You require complex navigation or animated transitions between pages
Strengths
- Reduces initial build cost by loading pages lazily
- Simple API that mirrors IndexedStack usage
- Allows selective preloading of specific children
Weaknesses
- Requires wrapping each child in IndexedStackChild
- First‑time switch may be delayed in debug mode
- Limited to lazy loading; no built‑in animation support
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
ProsteIndexedStack(
index: _current,
children: [
IndexedStackChild(child: HomePage()),
IndexedStackChild(child: Page2()),
IndexedStackChild(child: Page3(), preload: true),
IndexedStackChild(child: Page4()),
],
)Alternatives
Packages that do the same job and could replace proste_indexed_stack.
- expandable_page_view
A PageView widget that automatically adjusts its height to the currently displayed page.
88Compare - flutter_lazy_indexed_stack
An IndexedStack widget that loads children lazily only when needed.
57Compare - flutter_pagewise
Widgets for lazy-loading lists and grids with pagination support.
50Compare - loadmore_listview
A ListView with load more and pull‑to‑refresh support
44Compare