replaceSections method

void replaceSections(
  1. List<NavSection<T>> sections
)

Replace the whole section forest (e.g. permissions changed).

Implementation

void replaceSections(List<NavSection<T>> sections) {
  _sections = List.unmodifiable(sections);
  if (_active != null && node(_active!) == null) _active = null;
  notifyListeners();
}