Skip to content

Abstract States, Non-Abstract Parent States and Default Child States #27

Closed
@timkindberg

Description

@timkindberg

I know we went back and forth on this several times already, but I think I may have found a need for this feature again.

It seems as though we are trying to get to a place where states can function completely on their own without any url routing (correct?). So how would we know which child state to load automatically without specifying a url of ''? Seems like we would need a default boolean property or something similar.

Let me also attempt to define abstract states, and non-abstract parent states. Please let me know if I'm on the right track.

Abstract State

  • must be a parent state
  • a state that cannot be activated directly (via transitionTo method) without activating one of its children.
  • must have a default child state (either with empty url or default property)
  • if no default child state is set, first child state found will be used as default
  • can be navigated to via url, but this really just activates default child state

Non-Abstract Parent State

  • a normal state which has child states
  • can be activated and navigated to directly (via transitionTo method or url), though any view directives will not be populated until navigation to on of it's child state OR one of its child states is set as default child (either with empty url or default property)
  • default child state is optional

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions