analytics
packages, their actions will be centralized by the analytics
namespace.frontity.settings.js
we can enable/disable specific analytics packages for pageviews or events through the following properties in the state
(under the analytics
namespace):state.analytics.pageviews
state.analytics.events
frontity.settings.js
from state.analytics
...state.analytics.pageviews
actions.analytics.pageview
to know which analytics packages should send the pageview to their respective services.false
.true
by default in this setting.state.analytics.events
actions.analytics.event
to know which analytics packages should send the event to their respective services.false
.true
by default in this setting.actions
under the namespace analytics
will be ready to be used:actions.analytics.pageview
actions.analytics.event
actions.analytics.pageview
state.analytics.pageviews
that are true
and calls the pageview
action of each one with the specified Pageview
object.actions.analytics.pageview
is automatically launched every time link changes (or every time action.router.set(link)
is launched).actions.analytics.event
state.analytics.events
that are true
and calls the event
action of each one with the specified Event
object.actions.analytics.event()
must receive an event object with the following properties.name
payload
state.analytics.events
.actions.analytics.event()
in a different way: