New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ts-commons

Package Overview
Dependencies
Maintainers
1
Versions
82
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-commons - npm Package Compare versions

Comparing version 1.0.12 to 1.0.13

10

dist/index.d.ts

@@ -0,9 +1,9 @@

import { ArrayUtils } from "./utils/array.utils";
import { DateUtils } from "./utils/date.utils";
import { HttpUtils } from "./utils/http.utils";
import { NumberUtils } from "./utils/number.utils";
import { ObjectUtils } from "./utils/object.utils";
import { RegexUtils } from "./utils/regex.utils";
import { StringUtils } from "./utils/string.utils";
import { NumberUtils } from "./utils/number.utils";
import { DateUtils } from "./utils/date.utils";
import { RegexUtils } from "./utils/regex.utils";
import { HttpUtils } from "./utils/http.utils";
import { ArrayUtils } from "./utils/array.utils";
import { ThreadUtils } from "./utils/thread.utils";
export { ObjectUtils, StringUtils, NumberUtils, DateUtils, RegexUtils, HttpUtils, ArrayUtils, ThreadUtils };
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var array_utils_1 = require("./utils/array.utils");
exports.ArrayUtils = array_utils_1.ArrayUtils;
var date_utils_1 = require("./utils/date.utils");
exports.DateUtils = date_utils_1.DateUtils;
var http_utils_1 = require("./utils/http.utils");
exports.HttpUtils = http_utils_1.HttpUtils;
var number_utils_1 = require("./utils/number.utils");
exports.NumberUtils = number_utils_1.NumberUtils;
var object_utils_1 = require("./utils/object.utils");
exports.ObjectUtils = object_utils_1.ObjectUtils;
var regex_utils_1 = require("./utils/regex.utils");
exports.RegexUtils = regex_utils_1.RegexUtils;
var string_utils_1 = require("./utils/string.utils");
exports.StringUtils = string_utils_1.StringUtils;
var number_utils_1 = require("./utils/number.utils");
exports.NumberUtils = number_utils_1.NumberUtils;
var date_utils_1 = require("./utils/date.utils");
exports.DateUtils = date_utils_1.DateUtils;
var regex_utils_1 = require("./utils/regex.utils");
exports.RegexUtils = regex_utils_1.RegexUtils;
var http_utils_1 = require("./utils/http.utils");
exports.HttpUtils = http_utils_1.HttpUtils;
var array_utils_1 = require("./utils/array.utils");
exports.ArrayUtils = array_utils_1.ArrayUtils;
var thread_utils_1 = require("./utils/thread.utils");
exports.ThreadUtils = thread_utils_1.ThreadUtils;
//# sourceMappingURL=index.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var number_utils_1 = require("./number.utils");
var object_utils_1 = require("./object.utils");
var number_utils_1 = require("./number.utils");
var ArrayUtils = /** @class */ (function () {

@@ -6,0 +6,0 @@ function ArrayUtils() {

@@ -18,6 +18,3 @@ export declare class HttpUtils {

};
static toQueryParamsString(queryParams: {
[key: string]: any;
}): string;
private static getParams;
}

@@ -28,7 +28,2 @@ "use strict";

};
HttpUtils.toQueryParamsString = function (queryParams) {
if (object_utils_1.ObjectUtils.isNullOrUndefined(queryParams)) {
return "";
}
};
// solve a=1[;|&]b=2[;|&]c=3

@@ -35,0 +30,0 @@ HttpUtils.getParams = function (paramStr, splitChar) {

@@ -77,7 +77,10 @@ export declare class ObjectUtils {

* @param value
* @example ObjectUtils.toSafeString(null) = ""
* @example ObjectUtils.toSafeString(undefined) = ""
* @example ObjectUtils.toSafeString("test") = "test"
* @param defaultValue
* @example ObjectUtils.toSafeString(null) = ""
* @example ObjectUtils.toSafeString(undefined) = ""
* @example ObjectUtils.toSafeString("test") = "test"
* @example ObjectUtils.toSafeString(null, "--") = "--"
* @example ObjectUtils.toSafeString(undefined, "--") = "--"
*/
static toSafeString(value: any): string;
static toSafeString(value: any, defaultValue?: string): string;
/**

@@ -105,3 +108,3 @@ * get property value of object by key.

*/
static getPropertyName<T>(key: keyof T): any;
static getPropertyName<T>(key: keyof T): string;
static values(obj: any): any[];

@@ -108,0 +111,0 @@ /**

@@ -97,9 +97,13 @@ "use strict";

* @param value
* @example ObjectUtils.toSafeString(null) = ""
* @example ObjectUtils.toSafeString(undefined) = ""
* @example ObjectUtils.toSafeString("test") = "test"
* @param defaultValue
* @example ObjectUtils.toSafeString(null) = ""
* @example ObjectUtils.toSafeString(undefined) = ""
* @example ObjectUtils.toSafeString("test") = "test"
* @example ObjectUtils.toSafeString(null, "--") = "--"
* @example ObjectUtils.toSafeString(undefined, "--") = "--"
*/
ObjectUtils.toSafeString = function (value) {
ObjectUtils.toSafeString = function (value, defaultValue) {
if (defaultValue === void 0) { defaultValue = ""; }
if (this.isNullOrUndefined(value)) {
return "";
return defaultValue;
}

@@ -106,0 +110,0 @@ else {

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var number_utils_1 = require("./number.utils");
var object_utils_1 = require("./object.utils");
var number_utils_1 = require("./number.utils");
var StringUtils = /** @class */ (function () {

@@ -6,0 +6,0 @@ function StringUtils() {

{
"name": "ts-commons",
"version": "1.0.12",
"version": "1.0.13",
"description": "common methods for typescript",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc