🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@types/registry-auth-token

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/registry-auth-token - npm Package Compare versions

Comparing version
4.2.4
to
5.0.1
+7
-30
registry-auth-token/package.json
{
"name": "@types/registry-auth-token",
"version": "4.2.4",
"description": "TypeScript definitions for registry-auth-token",
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/registry-auth-token",
"version": "5.0.1",
"description": "Stub TypeScript definitions entry for registry-auth-token, which provides its own types definitions",
"main": "",
"scripts": {},
"license": "MIT",
"contributors": [
{
"name": "Maurice de Beijer",
"githubUsername": "mauricedb",
"url": "https://github.com/mauricedb"
},
{
"name": "James Liang",
"githubUsername": "LiangZugeng",
"url": "https://github.com/LiangZugeng"
},
{
"name": "Piotr Błażejewicz",
"githubUsername": "peterblazejewicz",
"url": "https://github.com/peterblazejewicz"
}
],
"main": "",
"types": "index.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
"directory": "types/registry-auth-token"
"dependencies": {
"registry-auth-token": "*"
},
"scripts": {},
"dependencies": {},
"typesPublisherContentHash": "02060b6741c88a0018cf52222bf89b57a77ef36da4e7a36e308e603e6636dd8f",
"typeScriptVersion": "4.5"
"deprecated": "This is a stub types definition. registry-auth-token provides its own type definitions, so you do not need this installed."
}

@@ -1,15 +0,3 @@

# Installation
> `npm install --save @types/registry-auth-token`
This is a stub types definition for @types/registry-auth-token (https://github.com/rexxars/registry-auth-token#readme).
# Summary
This package contains type definitions for registry-auth-token (https://github.com/rexxars/registry-auth-token).
# Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/registry-auth-token.
### Additional Details
* Last updated: Tue, 07 Nov 2023 15:11:36 GMT
* Dependencies: none
# Credits
These definitions were written by [Maurice de Beijer](https://github.com/mauricedb), [James Liang](https://github.com/LiangZugeng), and [Piotr Błażejewicz](https://github.com/peterblazejewicz).
registry-auth-token provides its own type definitions, so you don't need @types/registry-auth-token installed!
/**
* Simple namespace describing the inputs and outputs for `registry-auth-token`
*/
declare namespace auth {
/**
* The options for passing into `registry-auth-token`
*/
interface AuthOptions {
/**
* Wether or not url's path parts are recursively trimmed from the registry
* url when searching for tokens
*/
recursive?: boolean | undefined;
/**
* An npmrc configuration object used when searching for tokens. If no object is provided,
* the `.npmrc` file at the base of the project is used.
*/
npmrc?: {
/**
* A registry url used for matching
*/
registry?: string | undefined;
/**
* Registry url's with token information
*/
[registryUrls: string]: string | undefined;
} | undefined;
}
/**
* The generated authentication information
*/
interface NpmCredentials {
/**
* The token representing the users credentials
*/
token: string;
/**
* The type of token
*/
type: "Basic" | "Bearer";
/**
* The username used in `Basic`
*/
username?: string | undefined;
/**
* The password used in `Basic`
*/
password?: string | undefined;
}
}
/**
* @param registryUrl - Either the registry url used
* for matching or a configuration object describing the contents of the .npmrc file
* @param [options] - a configuration object describing the
* contents of the .npmrc file. If an `npmrc` config object was passed in as the
* first parameter, this parameter is ignored.
* @returns The `NpmCredentials` object or undefined if no match found.
*/
declare function auth(
registryUrl: string | auth.AuthOptions,
options?: auth.AuthOptions,
): auth.NpmCredentials | undefined;
export = auth;
import { AuthOptions } from "./";
declare function registryUrl(scope: string, npmrc?: Pick<AuthOptions, "npmrc">): string;
export = registryUrl;