Skip to content
pubscout

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.

WASM-ready
$ flutter pub add proste_indexed_stack
Source repository

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.