Skip to content

Latest commit

 

History

History
196 lines (90 loc) · 2.58 KB

File metadata and controls

196 lines (90 loc) · 2.58 KB
hide_title true
custom_edit_url
pagination_prev
pagination_next

Home > @microsoft/rush-lib > ApprovedPackagesConfiguration

ApprovedPackagesConfiguration class

This represents the JSON file specified via the "approvedPackagesFile" option in rush.json.

Signature:

export declare class ApprovedPackagesConfiguration 

Constructors

Constructor

Modifiers

Description

(constructor)(jsonFilename)

Constructs a new instance of the ApprovedPackagesConfiguration class

Properties

Property

Modifiers

Type

Description

items

ApprovedPackagesItem<></>[]

Methods

Method

Modifiers

Description

addOrUpdatePackage(packageName, reviewCategory)

clear()

Clears all the settings, returning to an empty state.

getItemByName(packageName)

loadFromFile()

Loads the configuration data from the filename that was passed to the constructor.

saveToFile()

Loads the configuration data to the filename that was passed to the constructor.

tryLoadFromFile(approvedPackagesPolicyEnabled)

If the file exists, calls loadFromFile().