@letscooee/web-sdk 1.5.9 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,10 @@
1
+ /*!
2
+ localForage -- Offline Storage, Improved
3
+ Version 1.10.0
4
+ https://localforage.github.io/localForage
5
+ (c) 2013-2017 Mozilla, Apache License 2.0
6
+ */
7
+
1
8
  /*!
2
9
  * js-logger - http://github.com/jonnyreeves/js-logger
3
10
  * Jonny Reeves, http://jonnyreeves.co.uk/
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@letscooee/web-sdk",
3
3
  "description": "AI driven Personalized Notifications for Better Customer Engagement",
4
- "version": "1.5.9",
4
+ "version": "2.0.0",
5
5
  "scripts": {
6
6
  "lint": "eslint \"**/**/*.ts\" --max-warnings=0",
7
7
  "integrity": "./scripts/validate-integrity.sh",
@@ -10,7 +10,7 @@
10
10
  "build:main": "webpack",
11
11
  "build:shopify": "webpack --config ./webpack-shopify.config.js",
12
12
  "build:preview": "webpack --config ./webpack-preview.config.js",
13
- "build:production": "npm run build:main && npm run build:shopify && npm run build:preview",
13
+ "build:production": "./scripts/build-production.sh",
14
14
  "serve": "webpack serve",
15
15
  "serve:preview": "webpack serve --config ./webpack-preview.config.js",
16
16
  "serve:shopify": "webpack serve --config ./webpack-shopify.config.js",
@@ -44,6 +44,7 @@
44
44
  "css-loader": "^6.7.3",
45
45
  "eslint": "^8.7.0",
46
46
  "eslint-config-google": "^0.14.0",
47
+ "file-replace-loader": "^1.4.0",
47
48
  "jasmine-core": "^4.5.0",
48
49
  "karma": "^6.4.1",
49
50
  "karma-chrome-launcher": "^3.1.1",
@@ -67,6 +68,7 @@
67
68
  "hex-rgb": "^5.0.0",
68
69
  "hex-to-rgba": "^2.0.1",
69
70
  "js-logger": "^1.6.1",
71
+ "localforage": "^1.10.0",
70
72
  "rxjs": "^7.3.0",
71
73
  "stream-browserify": "^3.0.0",
72
74
  "ua-parser-js": "^1.0.32",
@@ -0,0 +1,5 @@
1
+ #!/bin/bash -e
2
+
3
+ npm run build:main -- --env cooeeEnv=production
4
+ npm run build:shopify -- --env cooeeEnv=production
5
+ npm run build:preview -- --env cooeeEnv=production
@@ -1,11 +1,13 @@
1
- const config = require('./webpack.config');
2
- config.entry = './src/index-preview.ts';
3
- config.output.library = {
4
- name: 'CooeePreview',
5
- type: 'assign',
6
- export: 'default',
7
- };
8
- config.output.filename = 'sdk-preview.min.js';
9
- config.devServer.open = ['/index-preview.html']
1
+ module.exports = (env) => {
2
+ const config = require('./webpack.config')(env);
3
+ config.entry = './src/index-preview.ts';
4
+ config.output.library = {
5
+ name: 'CooeePreview',
6
+ type: 'assign',
7
+ export: 'default',
8
+ };
9
+ config.output.filename = 'sdk-preview.min.js';
10
+ config.devServer.open = ['/index-preview.html'];
10
11
 
11
- module.exports = config;
12
+ return config;
13
+ };
@@ -1,11 +1,13 @@
1
- const config = require('./webpack.config');
2
- config.entry = './src/shopify/index.ts';
3
- config.output.library = {
4
- name: 'CooeeShopify',
5
- type: 'assign',
6
- export: 'default',
7
- };
8
- config.output.filename = 'shopify-sdk.min.js';
9
- config.devServer.open = []
1
+ module.exports = (env) => {
2
+ const config = require('./webpack.config')(env);
3
+ config.entry = './src/shopify/index.ts';
4
+ config.output.library = {
5
+ name: 'CooeeShopify',
6
+ type: 'assign',
7
+ export: 'default',
8
+ };
9
+ config.output.filename = 'shopify-sdk.min.js';
10
+ config.devServer.open = ['/index-shopify.html'];
10
11
 
11
- module.exports = config;
12
+ return config;
13
+ };