EventNative is packaged and available as an npm module.
Use the following command to add it to your project:
npm install --save @ksense/eventnative
yarn add @ksense/eventnative
To initialize EventNative, please use:
const { eventN } = require('@ksense/eventnative');eventN.init({key: "[API_KEY]",...params});
Please, see the full list of parameters, a key parameter value is required.
To intercept Segment event it's recommended to initialize interception explicitely rather than use segment_hook parameter
eventN.init({...});//Create analytics via npm moduleconst analytics = new Analytics();//initialize interception explicitelyeventN.interceptAnalytics(analytics);