analytics-quala

0.0.0 • Public • Published

Quala plugin for analytics

Integration with quala for analytics

For more information see the docs.

Click to expand

Installation

npm install analytics
npm install @analytics/quala

How to use

The @analytics/quala package works in the browser and server-side in Node.js. To use, install the package, include in your project and initialize the plugin with analytics.

Below is an example of how to use the browser plugin. You must pass writeKey to the plugin.

import Analytics from "analytics";
import qualaPlugin from "@analytics/quala";

const analytics = Analytics({
  app: "awesome-app",
  plugins: [
    qualaPlugin({
      writeKey: "123-xyz",
    }),
    // ... more plugins
  ],
});

/* Track a page view */
analytics.page();

/* Track a custom event */
analytics.track("cartCheckout", {
  item: "pink socks",
  price: 20,
  companyId: "123-xyz",
});

/* Identify a visitor */
analytics.identify("user-id-xyz", {
  firstName: "bill",
  lastName: "murray",
  companyId: "123-xyz",
});

After initializing analytics with the qualaPlugin plugin, data will be sent into Quala whenever analytics.page, analytics.track, or analytics.identify are called.

See additional implementation examples for more details on using in your project.

Platforms Supported

The @analytics/quala package works in the browser and server-side in Node.js

Package Sidebar

Install

npm i analytics-quala

Weekly Downloads

1

Version

0.0.0

License

MIT

Unpacked Size

11.2 kB

Total Files

8

Last publish

Collaborators

  • boxgames