introduced view-context and apply-to-state