Skip to content

Commit

Permalink
Merge branch 'release-1.21.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
jsconan committed Nov 7, 2022
2 parents 0737c10 + dc4ad86 commit 5b23db3
Show file tree
Hide file tree
Showing 100 changed files with 3,380 additions and 3,197 deletions.
6 changes: 5 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
module.exports = {
root: true,
extends: "@oat-sa/eslint-config-tao/amd"
extends: '@oat-sa/eslint-config-tao/amd',
parserOptions: {
// needed to support the dynamic import syntax
ecmaVersion: 11
}
};
10 changes: 7 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,13 @@ typings/
# next.js build output
.next

dist
# IDE files
.idea/
.vscode/

# IDE
.vscode
# Platform specifics
.DS_Store

# Project related
eslint_report.json
/dist
17 changes: 8 additions & 9 deletions build/path.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,14 @@
*/

/**
* This file contains path definitions for build scripts.
*/
const path = require("path");
const rootPath = path.resolve(__dirname, "..");
* This file contains path definitions for build scripts.
*/
const path = require('path');
const rootPath = path.resolve(__dirname, '..');

module.exports = {
srcDir: path.resolve(rootPath, "src"),
testDir: path.resolve(rootPath, "test"),
outputDir: path.resolve(rootPath, "dist"),
testOutputDir: path.resolve(rootPath, "test")
srcDir: path.resolve(rootPath, 'src'),
testDir: path.resolve(rootPath, 'test'),
outputDir: path.resolve(rootPath, 'dist'),
testOutputDir: path.resolve(rootPath, 'test')
};

2,793 changes: 1,537 additions & 1,256 deletions package-lock.json

Large diffs are not rendered by default.

40 changes: 21 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@oat-sa/tao-core-sdk",
"version": "1.20.1",
"version": "1.21.0",
"displayName": "TAO Core SDK",
"description": "Core libraries of TAO",
"homepage": "https://github.com/oat-sa/tao-core-sdk-fe#readme",
Expand All @@ -11,7 +11,7 @@
"license": "GPL-2.0",
"scripts": {
"test": "npx qunit-testrunner",
"test:keepAlive": "npx qunit-testrunner --keepalive",
"test:keepAlive": "npx qunit-testrunner --keepalive --port 5300",
"test:cov": "npm run build:cov && npx qunit-testrunner --cov",
"test:dev": "NODE_ENV=development run-p test:keepAlive build:watch ",
"coverage": "nyc report",
Expand Down Expand Up @@ -41,45 +41,47 @@
"access": "public"
},
"devDependencies": {
"@babel/core": "^7.15.5",
"@babel/preset-env": "^7.15.6",
"@babel/core": "^7.19.3",
"@babel/preset-env": "^7.19.4",
"@oat-sa/browserslist-config-tao": "^1.0.1",
"@oat-sa/eslint-config-tao": "^1.1.1",
"@oat-sa/expr-eval": "^1.3.0",
"@oat-sa/expr-eval": "^1.3.1",
"@oat-sa/prettier-config": "^0.1.1",
"@oat-sa/tao-core-libs": "^0.4.3",
"@oat-sa/tao-core-libs": "^0.4.8",
"@oat-sa/tao-qunit-testrunner": "1.0.3",
"async": "^0.2.10",
"decimal.js": "10.1.1",
"dompurify": "1.0.11",
"eslint": "^7.32.0",
"dompurify": "^2.4.0",
"eslint": "^8.25.0",
"eslint-plugin-es": "^4.1.0",
"eslint-plugin-jsdoc": "^39.3.6",
"fetch-mock": "^9.4.0",
"gamp": "0.2.1",
"glob": "^7.1.3",
"glob": "^8.0.3",
"handlebars": "1.3.0",
"interactjs": "1.2.8",
"interactjs": "1.3.4",
"jquery": "1.9.1",
"jquery-mockjax": "^2.5.0",
"jquery-simulate": "^1.0.2",
"lodash": "2.4.1",
"mime": "^2.4.2",
"moment": "2.11.1",
"moment-timezone": "0.5.10",
"moment": "^2.29.4",
"moment-timezone": "^0.5.37",
"node-qunit-puppeteer": "^1.0.13",
"npm-run-all": "^4.1.5",
"nyc": "^15.0.1",
"open-cli": "^7.0.1",
"open-cli": "^7.1.0",
"popper.js": "1.15.0",
"prettier": "^2.1.2",
"prettier": "^2.7.1",
"promise-limit": "^2.7.0",
"qunit": "^2.17.2",
"qunit": "^2.19.1",
"raphael": "2.3.0",
"require-css": "^0.1.10",
"requirejs-plugins": "^1.0.2",
"rollup": "^1.16.7",
"rollup-plugin-alias": "^1.5.1",
"rollup-plugin-babel": "^4.3.3",
"rollup-plugin-commonjs": "^10.0.1",
"rollup": "^1.32.1",
"rollup-plugin-alias": "^1.5.2",
"rollup-plugin-babel": "^4.4.0",
"rollup-plugin-commonjs": "^10.1.0",
"rollup-plugin-istanbul": "^2.0.1",
"rollup-plugin-json": "^4.0.0",
"rollup-plugin-node-resolve": "^5.2.0",
Expand Down
18 changes: 9 additions & 9 deletions src/core/cachedStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import store from 'core/store';
* The default name of the key storage indexing the persisted data
* @type {String}
*/
var defaultKey = 'cachedData';
const defaultKey = 'cachedData';

/**
* Builds a cached store.
Expand All @@ -38,8 +38,8 @@ var defaultKey = 'cachedData';
function cachedStoreFactory(storageName, storageKey) {
storageKey = storageKey || defaultKey;

return store(storageName).then(function(storage) {
return storage.getItem(storageKey).then(function(data) {
return store(storageName).then(function (storage) {
return storage.getItem(storageKey).then(function (data) {
// the persisted data set is always an object
data = data || {};

Expand All @@ -52,7 +52,7 @@ function cachedStoreFactory(storageName, storageKey) {
* @param {String} name
* @returns {Object}
*/
getItem: function getItem(name) {
getItem(name) {
return data[name];
},

Expand All @@ -62,7 +62,7 @@ function cachedStoreFactory(storageName, storageKey) {
* @param {Object} value
* @returns {Promise} Returns a promise that will be resolved if the data have been successfully stored
*/
setItem: function setItem(name, value) {
setItem(name, value) {
data[name] = value;
return storage.setItem(storageKey, data);
},
Expand All @@ -72,16 +72,16 @@ function cachedStoreFactory(storageName, storageKey) {
* @param {String} name
* @returns {Promise} Returns a promise that will be resolved if the data have been successfully stored
*/
removeItem: function removeItem(name) {
data[name] = undefined;
removeItem(name) {
data[name] = void 0;
return storage.setItem(storageKey, data);
},

/**
* Clears the full data set
* @returns {Promise} Returns a promise that will be resolved if the data have been successfully erased
*/
clear: function clear() {
clear() {
data = {};
return storage.removeItem(storageKey);
},
Expand All @@ -90,7 +90,7 @@ function cachedStoreFactory(storageName, storageKey) {
* Delete the database related to the current store
* @returns {Promise} with true in resolve once cleared
*/
removeStore: function removeStore() {
removeStore() {
data = {};
return storage.removeStore();
}
Expand Down
Loading

0 comments on commit 5b23db3

Please sign in to comment.