Skip to content

dispatch to data layer not referenced in window #71

Open
@debuggingfuture

Description

Currently process() & dispatch() only take argument data. Does that imply the data layer must be referenced in window? e.g. window. dataLayer

My case is I'm using https://github.com/mobxjs/mobx-react where I would like to put the data layer inside props.rootStore. I don't see a way to have it available inside dispatch(), even the react component is a child of the StoreProvider. I tried to hack around with process() but seems the merge will make observers converted to plain object.

Is dispatch(data,props) feasible?

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions