Skip to content

Commit 50fc721

Browse files
alan-agius4hansl
authored andcommitted
feat(@schematics/angular): add support for watch when building a library
`ng-packagr` version `4.0.0-rc.3`, lands the incremental builds feature. More info: https://github.com/dherges/ng-packagr/blob/master/CHANGELOG.md#400-rc2-2018-06-23 `enableResourceInlining` needs to be enabled for libraries that contain components Closes: #11100
1 parent c0a5089 commit 50fc721

File tree

4 files changed

+0
-15
lines changed

4 files changed

+0
-15
lines changed

packages/schematics/angular/library/files/__projectRoot__/ng-package.json

-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"$schema": "<%= relativePathToWorkspaceRoot %>/node_modules/ng-packagr/ng-package.schema.json",
33
"dest": "<%= relativePathToWorkspaceRoot %>/<%= distRoot %>",
4-
"deleteDestPath": false,
54
"lib": {
65
"entryFile": "src/<%= entryFile %>.ts"
76
}

packages/schematics/angular/library/files/__projectRoot__/ng-package.prod.json

-7
This file was deleted.

packages/schematics/angular/library/index.ts

-6
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ import { latestVersions } from '../utility/latest-versions';
3535
import { validateProjectName } from '../utility/validation';
3636
import { Schema as LibraryOptions } from './schema';
3737

38-
3938
interface UpdateJsonFn<T> {
4039
(obj: T): T | void;
4140
}
@@ -145,11 +144,6 @@ function addAppToWorkspaceFile(options: LibraryOptions, workspace: WorkspaceSche
145144
tsConfig: `${projectRoot}/tsconfig.lib.json`,
146145
project: `${projectRoot}/ng-package.json`,
147146
},
148-
configurations: {
149-
production: {
150-
project: `${projectRoot}/ng-package.prod.json`,
151-
},
152-
},
153147
},
154148
test: {
155149
builder: '@angular-devkit/build-angular:karma',

packages/schematics/angular/library/index_spec.ts

-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@ describe('Library Schematic', () => {
7474
const fileContent = getJsonFileContent(tree, '/projects/foo/ng-package.json');
7575
expect(fileContent.lib).toBeDefined();
7676
expect(fileContent.lib.entryFile).toEqual('src/my_index.ts');
77-
expect(fileContent.deleteDestPath).toEqual(false);
7877
expect(fileContent.dest).toEqual('../../dist/foo');
7978
});
8079

0 commit comments

Comments
 (0)