Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
bef836fc83 | |||
2bd1741893 | |||
bd20512b10 | |||
25d0ba8036 |
23
package-lock.json
generated
23
package-lock.json
generated
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@pushrocks/smartstring",
|
||||
"version": "3.0.19",
|
||||
"version": "3.0.21",
|
||||
"lockfileVersion": 1,
|
||||
"requires": true,
|
||||
"dependencies": {
|
||||
@ -1350,8 +1350,7 @@
|
||||
"@pushrocks/isounique": {
|
||||
"version": "1.0.4",
|
||||
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fisounique/-/isounique-1.0.4.tgz",
|
||||
"integrity": "sha512-P1xLsuA1+8LQpoWCo2nP2vIQXKGUl5wDWU6CD7xTDZc3uw0He5V/qCPHM5zpIZsS7IuZOxDDpWb7aFveB11tXw==",
|
||||
"dev": true
|
||||
"integrity": "sha512-P1xLsuA1+8LQpoWCo2nP2vIQXKGUl5wDWU6CD7xTDZc3uw0He5V/qCPHM5zpIZsS7IuZOxDDpWb7aFveB11tXw=="
|
||||
},
|
||||
"@pushrocks/lik": {
|
||||
"version": "4.0.20",
|
||||
@ -3927,6 +3926,7 @@
|
||||
"version": "3.3.0",
|
||||
"resolved": "https://verdaccio.lossless.one/crypto-random-string/-/crypto-random-string-3.3.0.tgz",
|
||||
"integrity": "sha512-teWAwfMb1d6brahYyKqcBEb5Yp8PJPvPOdOonXDnvaKOTmKDFNVE8E3Y2XQuzjNV/3XMwHbrX9fHWvrhRKt4Gg==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"type-fest": "^0.8.1"
|
||||
}
|
||||
@ -7527,12 +7527,6 @@
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"nanoid": {
|
||||
"version": "2.1.11",
|
||||
"resolved": "https://verdaccio.lossless.one/nanoid/-/nanoid-2.1.11.tgz",
|
||||
"integrity": "sha512-s/snB+WGm6uwi0WjsZdaVcuf3KJXlfGl2LcxgwkEwJF0D/BWzVWAZW/XY4bFaiR7s0Jk3FPvlnepg1H1b1UwlA==",
|
||||
"dev": true
|
||||
},
|
||||
"nanomatch": {
|
||||
"version": "1.2.13",
|
||||
"resolved": "https://verdaccio.lossless.one/nanomatch/-/nanomatch-1.2.13.tgz",
|
||||
@ -9625,6 +9619,14 @@
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"nanoid": "^2.1.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"nanoid": {
|
||||
"version": "2.1.11",
|
||||
"resolved": "https://verdaccio.lossless.one/nanoid/-/nanoid-2.1.11.tgz",
|
||||
"integrity": "sha512-s/snB+WGm6uwi0WjsZdaVcuf3KJXlfGl2LcxgwkEwJF0D/BWzVWAZW/XY4bFaiR7s0Jk3FPvlnepg1H1b1UwlA==",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"signal-exit": {
|
||||
@ -10482,7 +10484,8 @@
|
||||
"type-fest": {
|
||||
"version": "0.8.1",
|
||||
"resolved": "https://verdaccio.lossless.one/type-fest/-/type-fest-0.8.1.tgz",
|
||||
"integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA=="
|
||||
"integrity": "sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA==",
|
||||
"dev": true
|
||||
},
|
||||
"type-is": {
|
||||
"version": "1.6.18",
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@pushrocks/smartstring",
|
||||
"version": "3.0.19",
|
||||
"version": "3.0.21",
|
||||
"private": false,
|
||||
"description": "handle strings in smart ways. TypeScript ready.",
|
||||
"main": "dist_ts/index.js",
|
||||
@ -33,8 +33,8 @@
|
||||
"tslint-config-prettier": "^1.18.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@pushrocks/isounique": "^1.0.4",
|
||||
"@pushrocks/smartenv": "^4.0.16",
|
||||
"crypto-random-string": "^3.3.0",
|
||||
"js-base64": "^2.5.1",
|
||||
"normalize-newline": "^3.0.0",
|
||||
"randomatic": "^3.1.1",
|
||||
|
@ -21,9 +21,9 @@ export const createRandomString = (
|
||||
};
|
||||
|
||||
/**
|
||||
* creates a crytic string in the speicifed length
|
||||
* creates a cryptic string in the speicifed length
|
||||
* @param lengthArg the length of the crypto string
|
||||
*/
|
||||
export const createCryptoRandomString = (lengthArg: number): string => {
|
||||
return plugins.cryptoRandomString(lengthArg);
|
||||
return plugins.isounique.uni();
|
||||
};
|
||||
|
@ -1,16 +1,31 @@
|
||||
// node native
|
||||
import * as smartenv from '@pushrocks/smartenv';
|
||||
const smartenvInstance = new smartenv.Smartenv();
|
||||
const crypto = smartenvInstance.getSafeNodeModule('crypto');
|
||||
|
||||
// node native
|
||||
const crypto = smartenvInstance.getSafeNodeModule('crypto');
|
||||
import * as url from 'url';
|
||||
|
||||
export { crypto, url };
|
||||
|
||||
// third party
|
||||
export let jsBase64 = require('js-base64').Base64;
|
||||
// pushrocks scope
|
||||
import * as isounique from '@pushrocks/isounique';
|
||||
|
||||
export let stripIndent = require('strip-indent');
|
||||
export let normalizeNewline = require('normalize-newline');
|
||||
export let randomatic = require('randomatic');
|
||||
export let cryptoRandomString = require('crypto-random-string');
|
||||
export {
|
||||
isounique
|
||||
};
|
||||
|
||||
// third party
|
||||
const jsBase64 = require('js-base64').Base64;
|
||||
|
||||
const stripIndent = require('strip-indent');
|
||||
const normalizeNewline = require('normalize-newline');
|
||||
const randomatic = require('randomatic');
|
||||
|
||||
|
||||
|
||||
export {
|
||||
jsBase64,
|
||||
stripIndent,
|
||||
normalizeNewline,
|
||||
randomatic,
|
||||
}
|
||||
|
Reference in New Issue
Block a user