ng-packagr
Version:
Compile and package Angular libraries in Angular Package Format (APF)
122 lines (121 loc) • 4.08 kB
JSON
{
"$schema": "http://json-schema.org/draft-07/schema",
"$id": "https://github.com/ng-packagr/ng-packagr/blob/master/src/ng-package.schema.json",
"title": "NgPackageConfig",
"description": "JSON Schema for `ng-package.json` description file",
"type": "object",
"properties": {
"$schema": {
"type": "string"
},
"deleteDestPath": {
"description": "Delete output path before build.",
"type": "boolean",
"default": true
},
"dest": {
"description": "Destination folder where distributable binaries of the Angular library are written (default: `dist`).",
"type": "string",
"default": "dist"
},
"keepLifecycleScripts": {
"description": "Enable this to keep the 'scripts' section in package.json. Read the NPM Blog on 'Package install scripts vulnerability' – http://blog.npmjs.org/post/141702881055/package-install-scripts-vulnerability",
"type": "boolean",
"default": false
},
"allowedNonPeerDependencies": {
"description": "A list of dependencies that are allowed in the 'dependencies' and 'devDependencies' section of package.json. Values in the list are regular expressions matched against npm package names.",
"type": "array",
"items": {
"type": "string"
},
"default": []
},
"assets": {
"type": "array",
"description": "A list of files which are simply copied into the package.",
"items": {
"$ref": "#/definitions/assetPattern"
},
"default": []
},
"inlineStyleLanguage": {
"description": "The stylesheet language to use for the library's inline component styles.",
"type": "string",
"default": "css",
"enum": ["css", "less", "sass", "scss"]
},
"lib": {
"description": "Description of the library's entry point.",
"type": "object",
"additionalProperties": false,
"default": {},
"properties": {
"entryFile": {
"description": "Entry file to the public API (default: `src/public_api.ts`).",
"type": "string",
"default": "src/public_api.ts"
},
"flatModuleFile": {
"description": "Filename of the auto-generated flat module file (if empty, defaults to the package name as given in `package.json`).",
"type": "string"
},
"cssUrl": {
"description": "Embed assets in css file using data URIs - see https://css-tricks.com/data-uris",
"type": "string",
"enum": ["none", "inline"],
"default": "inline"
},
"styleIncludePaths": {
"description": "Any additional paths that should be used to resolve style imports",
"type": "array",
"items": {
"type": "string"
}
}
}
}
},
"required": [],
"additionalProperties": false,
"definitions": {
"assetPattern": {
"oneOf": [
{
"type": "object",
"properties": {
"glob": {
"type": "string",
"description": "The pattern to match."
},
"input": {
"type": "string",
"description": "The input directory path in which to apply 'glob'. Defaults to the project root."
},
"ignore": {
"description": "An array of globs to ignore.",
"type": "array",
"items": {
"type": "string"
}
},
"output": {
"type": "string",
"description": "Absolute path within the output."
},
"followSymlinks": {
"type": "boolean",
"default": false,
"description": "Allow glob patterns to follow symlink directories. This allows subdirectories of the symlink to be searched."
}
},
"additionalProperties": false,
"required": ["glob", "input", "output"]
},
{
"type": "string"
}
]
}
}
}