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

ts-xor

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-xor - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

11

dist/types/Xor.type.d.ts

@@ -5,5 +5,14 @@ declare type Without<T, U> = {

/**
* TODO add jsdoc
* Returns a type composed with T and U, restricting usage of either
* exclusively to members of T or exclusively to members of U.
*
* No unique members of T can be used simultaneusly with any
* unique members of U.
*
* Example:
* `const myVar: XOR<T, U>`
*
* More: https://github.com/maninak/ts-xor/tree/master#description
*/
export declare type XOR<T, U> = (T | U) extends object ? (Without<T, U> & U) | (Without<U, T> & T) : T | U;
export {};

5

package.json
{
"name": "ts-xor",
"version": "1.0.0",
"version": "1.0.1",
"description": "Compose custom types containing mutually exclusive keys, using this generic Typescript helper type.",

@@ -10,3 +10,4 @@ "main": "dist/index.js",

"test": "echo \"Warning: no test specified\" && exit 0",
"preversion": "rimraf dist && npm run build && npm test"
"preversion": "rimraf dist && npm run build && npm test",
"postpublish": "git push --tags"
},

@@ -13,0 +14,0 @@ "repository": {

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