fix(core): update

This commit is contained in:
Philipp Kunz 2019-08-09 10:55:17 +02:00
parent d70310ce8b
commit b901f8604b
3 changed files with 65 additions and 33 deletions

78
package-lock.json generated
View File

@ -49,15 +49,39 @@
}
},
"@gitzone/tsrun": {
"version": "1.2.6",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftsrun/-/tsrun-1.2.6.tgz",
"integrity": "sha512-MTgQ7OiKfMpRQRumJp8aGuLCNNyWGjZSxsF+GfZ7cmg2DUtJRyCL0Ybkai1sPdMWG/zE8RUo50WvBKEChdVyvA==",
"version": "1.2.8",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftsrun/-/tsrun-1.2.8.tgz",
"integrity": "sha512-G65DNcjegxF6w/O9MYD2mlHh+QVUiLuZvgLD5eamOOuWLhzuiE1tDzv5praJ/woJQzzZinDs+IyRyZ5rWKp/fQ==",
"dev": true,
"requires": {
"@gitzone/tsbuild": "^2.1.8",
"@pushrocks/smartfile": "^7.0.2",
"ts-node": "^8.0.3",
"typescript": "^3.4.2"
"@pushrocks/smartfile": "^7.0.4",
"ts-node": "^8.3.0",
"typescript": "^3.5.3"
},
"dependencies": {
"@pushrocks/smartfile": {
"version": "7.0.4",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartfile/-/smartfile-7.0.4.tgz",
"integrity": "sha512-ym8eigWJAQhwgmuVLew3GLrk4WhV03ajapwuMWytxKSzfIW9ZqceJBX2QzOkmhFGA2bp+gc4Q2wOBy3Ffnlj+A==",
"dev": true,
"requires": {
"@pushrocks/smartpath": "^4.0.1",
"@pushrocks/smartpromise": "^3.0.2",
"@pushrocks/smartrequest": "^1.1.14",
"@types/fs-extra": "^5.0.5",
"@types/vinyl": "^2.0.2",
"fs-extra": "^7.0.1",
"glob": "^7.1.3",
"js-yaml": "^3.13.1",
"vinyl-file": "^3.0.0"
}
},
"typescript": {
"version": "3.5.3",
"resolved": "https://verdaccio.lossless.one/typescript/-/typescript-3.5.3.tgz",
"integrity": "sha512-ACzBtm/PhXBDId6a6sDJfroT2pOWt/oOnk4/dElG5G33ZL776N3Y6/6bKZJBFpd+b05F3Ct9qDjMeJmRWtE2/g==",
"dev": true
}
}
},
"@gitzone/tstest": {
@ -408,9 +432,9 @@
"dev": true
},
"@types/node": {
"version": "12.0.12",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-12.0.12.tgz",
"integrity": "sha512-Uy0PN4R5vgBUXFoJrKryf5aTk3kJ8Rv3PdlHjl6UaX+Cqp1QE0yPQ68MPXGrZOfG7gZVNDIJZYyot0B9ubXUrQ==",
"version": "12.7.1",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-12.7.1.tgz",
"integrity": "sha512-aK9jxMypeSrhiYofWWBf/T7O+KwaiAHzM4sveCdWPn71lzUSMimRnKzhXDKfKwV1kWoBo2P1aGgaIYGLf9/ljw==",
"dev": true
},
"@types/vinyl": {
@ -456,9 +480,9 @@
}
},
"arg": {
"version": "4.1.0",
"resolved": "https://verdaccio.lossless.one/arg/-/arg-4.1.0.tgz",
"integrity": "sha512-ZWc51jO3qegGkVh8Hwpv636EkbesNV5ZNQPCtRa+0qytRYPEs9IYT9qITY9buezqUH5uqyzlWLcufrzU2rffdg==",
"version": "4.1.1",
"resolved": "https://verdaccio.lossless.one/arg/-/arg-4.1.1.tgz",
"integrity": "sha512-SlmP3fEA88MBv0PypnXZ8ZfJhwmDeIE3SP71j37AiXQBXYosPV0x6uISAaHYSlSVhmHOVkomen0tbGk6Anlebw==",
"dev": true
},
"argparse": {
@ -1458,9 +1482,9 @@
"dev": true
},
"source-map-support": {
"version": "0.5.12",
"resolved": "https://verdaccio.lossless.one/source-map-support/-/source-map-support-0.5.12.tgz",
"integrity": "sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==",
"version": "0.5.13",
"resolved": "https://verdaccio.lossless.one/source-map-support/-/source-map-support-0.5.13.tgz",
"integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==",
"dev": true,
"requires": {
"buffer-from": "^1.0.0",
@ -1551,16 +1575,24 @@
"dev": true
},
"ts-node": {
"version": "8.1.0",
"resolved": "https://verdaccio.lossless.one/ts-node/-/ts-node-8.1.0.tgz",
"integrity": "sha512-34jpuOrxDuf+O6iW1JpgTRDFynUZ1iEqtYruBqh35gICNjN8x+LpVcPAcwzLPi9VU6mdA3ym+x233nZmZp445A==",
"version": "8.3.0",
"resolved": "https://verdaccio.lossless.one/ts-node/-/ts-node-8.3.0.tgz",
"integrity": "sha512-dyNS/RqyVTDcmNM4NIBAeDMpsAdaQ+ojdf0GOLqE6nwJOgzEkdRNzJywhDfwnuvB10oa6NLVG1rUJQCpRN7qoQ==",
"dev": true,
"requires": {
"arg": "^4.1.0",
"diff": "^3.1.0",
"diff": "^4.0.1",
"make-error": "^1.1.1",
"source-map-support": "^0.5.6",
"yn": "^3.0.0"
},
"dependencies": {
"diff": {
"version": "4.0.1",
"resolved": "https://verdaccio.lossless.one/diff/-/diff-4.0.1.tgz",
"integrity": "sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q==",
"dev": true
}
}
},
"tslib": {
@ -1770,9 +1802,9 @@
}
},
"yn": {
"version": "3.1.0",
"resolved": "https://verdaccio.lossless.one/yn/-/yn-3.1.0.tgz",
"integrity": "sha512-kKfnnYkbTfrAdd0xICNFw7Atm8nKpLcLv9AZGEt+kczL/WQVai4e2V6ZN8U/O+iI6WrNuJjNNOyu4zfhl9D3Hg==",
"version": "3.1.1",
"resolved": "https://verdaccio.lossless.one/yn/-/yn-3.1.1.tgz",
"integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==",
"dev": true
}
}

View File

@ -21,10 +21,10 @@
"homepage": "https://gitlab.com/pushrocks/smartjson#README",
"devDependencies": {
"@gitzone/tsbuild": "^2.1.11",
"@gitzone/tsrun": "^1.2.6",
"@gitzone/tsrun": "^1.2.8",
"@gitzone/tstest": "^1.0.24",
"@pushrocks/tapbundle": "^3.0.11",
"@types/node": "^12.0.12",
"@types/node": "^12.7.1",
"tslint": "^5.18.0",
"tslint-config-prettier": "^1.18.0"
},

View File

@ -4,9 +4,9 @@ export class Smartjson {
// ======
// STATIC
// ======
static parse = JSON.parse;
public static parse = JSON.parse;
static stringify = (objArg: any, optionsArg: plugins.stableJson.Options) => {
public static stringify = (objArg: any, optionsArg: plugins.stableJson.Options) => {
return plugins.stableJson(objArg, optionsArg);
};
@ -14,14 +14,14 @@ export class Smartjson {
// INSTANCE
// ========
saveableProperties: string[];
public saveableProperties: string[];
/**
* folds a class into an object
*/
foldToObject() {
let newFoldedObject: { [key: string]: any } = {};
for (let keyName of this.saveableProperties) {
public foldToObject() {
const newFoldedObject: { [key: string]: any } = {};
for (const keyName of this.saveableProperties) {
newFoldedObject[keyName] = plugins.lodashCloneDeep(this[keyName]);
}
return newFoldedObject;
@ -30,8 +30,8 @@ export class Smartjson {
/**
* enfolds data from an object
*/
enfoldFromObject(objectArg) {
for (let keyName in objectArg) {
public enfoldFromObject(objectArg) {
for (const keyName in objectArg) {
if (this.saveableProperties.indexOf(keyName) !== -1) {
this[keyName] = objectArg[keyName];
}