Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
"no-prototype-builtins": "off",
"no-empty": "off",
"no-useless-escape": "off",
"no-unexpected-multiline": "off"
"no-unexpected-multiline": "off",
"no-unused-vars": ["error", { "argsIgnorePattern": "^_", "varsIgnorePattern": "^_" }]
}
}
}
27 changes: 27 additions & 0 deletions .github/workflows/dependabot-auto-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Dependabot Auto Merge
Comment thread
crisryantan marked this conversation as resolved.
Outdated

on: [push, pull_request]

jobs:
build-and-test:
name: Run tests
runs-on: ubuntu-latest
steps:
- name: Git checkout
uses: actions/checkout@v2

- name: Install dependencies, build, then test
run: |
npm install
npm run build
npm run test

automerge:
needs: build-and-test
runs-on: ubuntu-latest
steps:
- uses: fastify/github-action-merge-dependabot@v1
if: ${{ github.actor == 'dependabot[bot]' && github.event_name == 'pull_request' }}
with:
github-token: ${{secrets.github_token}}
merge-method: 'squash'
32 changes: 32 additions & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Web Kit Build & Test
Comment thread
crisryantan marked this conversation as resolved.
Outdated

on: pull_request

jobs:
build-and-test:
name: Build and Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: NPM install
uses: actions/setup-node@v4
with:
node-version: 20.x

- name: Run NPM CI
run: npm ci

- name: Build Files
run: npm run build

- name: Run Core tests
run: npm run test

- name: Archive npm failure logs
uses: actions/upload-artifact@v4
if: failure()
with:
name: npm-logs
path: ~/.npm/_logs
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -145,4 +145,4 @@ jobs:
- name: Delete release branch
if: ${{ github.event.inputs.dryRun == 'false' }}
run: |
git push --delete origin release/${{ github.run_number }}
git push --delete origin release/${{ github.run_number }}
Comment thread
crisryantan marked this conversation as resolved.
Outdated
2 changes: 1 addition & 1 deletion .github/workflows/reusable-workflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
uses: mParticle/mparticle-workflows/.github/workflows/pr-title-check.yml@stable
pr-branch-target-gitflow:
name: Check PR for semantic target branch
uses: mParticle/mparticle-workflows/.github/workflows/pr-branch-target-gitflow.yml@stable
uses: mParticle/mparticle-workflows/.github/workflows/pr-branch-target-gitflow.yml@stable
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ node_modules/
test/test-bundle.js
.DS_Store
test/end-to-end-testapp/build/compilation.js
dist/
dist/
6 changes: 5 additions & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
v20.13.1
<<<<<<< HEAD
v20.13.1
=======
v20.13.1
>>>>>>> development
Comment thread
crisryantan marked this conversation as resolved.
Outdated
14 changes: 14 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
language: node_js
Comment thread
crisryantan marked this conversation as resolved.
Outdated
node_js:
- "7"
dist: trusty
sudo: required
addons:
chrome: stable
firefox: latest
cache:
directories:
- node_modules
script:
- npm install
- npm run testKarma -- --single-run=true --browsers=ChromeHeadless,FirefoxHeadless
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,26 @@
# mparticle-javascript-integration-rokt
# mParticle JS Example Web Integration
Comment thread
crisryantan marked this conversation as resolved.
Outdated

A web integration (or a kit) is an extension to the core [mParticle Web SDK](https://github.com/mParticle/mparticle-web-sdk). A kit works as a bridge between the mParticle SDK and a partner SDK. It abstracts the implementation complexity, simplifying the implementation for developers.

A kit takes care of initializing and forwarding information depending on what you've configured in [mParticle's dashboard](https://app.mparticle.com).

## Create Your Own Integration

Detailed instructions on how to implement your own integration with the mParticle Web SDK can be found [here](https://docs.mparticle.com/developers/partners/kit-integrations/javascript-kit), but you can view a quick start guide below.

## Quick Start Guide

1. Fork this repo and `cd` into it locally on your computer.
2. Run `npm install` to install dependencies.
3. Run `KIT=YOURKITNAME npm run watch` to watch files in the `src/` folder, and automatically build your kit to `dist/YOURKITNAME-Kit.iife.js`. Your kit will continuously build as your save your edits.
4. Following examples such as [Optimizely](https://github.com/mparticle-integrations/mparticle-javascript-integration-optimizely), edit files in `src/`.
5. As you map mParticle's methods to your own in `src/`, stub your SDK methods and create tests in `test/tests.js`.
6. Submit a pull request to this repo. A developer from mParticle will review it and once complete, we will help provide you with a repo for your integration.

## Support

Questions? Give us a shout at <support@mparticle.com>

## License

This mParticle Web Kit is available under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0). See the LICENSE file for more info.
Empty file added dist/.keep
Empty file.
Loading