Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ts-common/source-map

Package Overview
Dependencies
Maintainers
3
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ts-common/source-map - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

4

index.d.ts

@@ -37,4 +37,4 @@ import { StringMap } from "@ts-common/string-map";

export declare const setInfo: <T extends object>(value: T, info: ObjectInfo) => Tracked<T>;
export declare const getInfoFunc: (value: object) => InfoFunc | undefined;
export declare const getInfo: (value: object) => RootObjectInfo | ChildObjectInfo | undefined;
export declare const getInfoFunc: (value: object | undefined) => InfoFunc | undefined;
export declare const getInfo: (value: object | undefined) => RootObjectInfo | ChildObjectInfo | undefined;
export declare const copyInfo: <T extends object>(source: object, dest: T) => T;

@@ -41,0 +41,0 @@ export declare type Data = object | JsonPrimitive;

@@ -31,2 +31,5 @@ "use strict";

exports.getInfoFunc = (value) => {
if (value === undefined) {
return undefined;
}
const withInfo = value;

@@ -33,0 +36,0 @@ return withInfo[exports.objectInfoSymbol];

@@ -83,3 +83,6 @@ import { StringMap } from "@ts-common/string-map"

export const getInfoFunc = (value: object): InfoFunc|undefined => {
export const getInfoFunc = (value: object | undefined): InfoFunc|undefined => {
if (value === undefined) {
return undefined
}
const withInfo = value as Tracked<object>

@@ -89,3 +92,3 @@ return withInfo[objectInfoSymbol]

export const getInfo = (value: object): ObjectInfo|undefined => {
export const getInfo = (value: object | undefined): ObjectInfo|undefined => {
const f = getInfoFunc(value)

@@ -92,0 +95,0 @@ return f === undefined ? undefined : f()

{
"name": "@ts-common/source-map",
"version": "0.3.0",
"version": "0.3.1",
"description": "Source Map",

@@ -8,3 +8,3 @@ "main": "index.js",

"tsc": "tsc",
"test": "tsc && nyc mocha",
"test": "tsc && nyc mocha --reporter mocha-junit-reporter",
"prepack": "npm install && tsc"

@@ -14,5 +14,11 @@ },

"reporter": [
"lcov",
"text"
]
"html",
"text",
"cobertura"
],
"check-coverage": true,
"lines": 100,
"statements": 100,
"functions": 100,
"branches": 100
},

@@ -46,2 +52,3 @@ "types": "index.d.ts",

"mocha": "^5.2.0",
"mocha-junit-reporter": "^1.18.0",
"nyc": "^13.1.0",

@@ -48,0 +55,0 @@ "tslib": "^1.9.3",

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