Google Analytics
var Analytics = require("bauplan.analytics");
or as part of the Bauplan bundle
var Bauplan = require("bauplan");
var Analytics = Bauplan.Analytics;
To record a pageview
Analytics.pageview("/foo");
To record a transaction
Analytics.transaction();
These methods should not usually be called directly, since they are called from within the corresponding methods in bauplan.tracker
Returns
Analytics
- Type
- instance
- Source:
- See:
Methods
pageview(url)
Record a pageview
Parameters
Name | Type | Description |
---|---|---|
url |
string | URL to be recorded |
- Source:
transaction(transaction)
Record a transaction
Parameters
Name | Type | Description |
---|---|---|
transaction |
object | Transaction details to be recorded |
- Source: