Sitelet https://github.com/coderenaissance/knockout.viewmodel/issues/42
Skip to content

access parent object of view model #42

Description

@nmehlei

Hey,
I'm currently migrating from the knockout mapping plugin to this plugin. One thing I did with the mapping plugin was to build constructor functions (pseudo-classes) for my more complex view models. This allowed me, through custom instantiation, to give those a reference to their parent view model. For example, order view model could get reference to Customer view model etc. Obviously one should try to minimize those connections, but sometimes they aren't avoidable.
While rebuilding those view models with the viewmodel-plugin, how does one do that here? With the extend mapping option, I don't see a way to get to a reference, since there is only the single argument.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions