fix(packages): use ES modules for primary build (#11120)

This commit is contained in:
Miško Hevery
2016-08-30 18:07:40 -07:00
committed by Victor Berchet
parent 8cb1046ce9
commit 979657989b
249 changed files with 1929 additions and 1463 deletions

View File

@ -6,4 +6,11 @@
* found in the LICENSE file at https://angular.io/license
*/
/**
* @module
* @description
* Entry point for all public APIs of the forms package.
*/
export * from './src/forms';
// This file only reexports content of the `src` folder. Keep it that way.

View File

@ -1,16 +1,15 @@
{
"name": "@angular/forms",
"version": "0.0.0-PLACEHOLDER",
"description": "",
"main": "index.js",
"jsnext:main": "esm/index.js",
"description": "Angular 2 forms",
"main": "bundles/forms.umd.js",
"module": "index.js",
"typings": "index.d.ts",
"author": "angular",
"license": "MIT",
"peerDependencies": {
"@angular/core": "0.0.0-PLACEHOLDER",
"@angular/common": "0.0.0-PLACEHOLDER",
"@angular/compiler": "0.0.0-PLACEHOLDER"
"@angular/common": "0.0.0-PLACEHOLDER"
},
"repository": {
"type": "git",

View File

@ -1,7 +1,7 @@
export default {
entry: '../../../dist/packages-dist/forms/esm/index.js',
dest: '../../../dist/packages-dist/forms/esm/forms.umd.js',
entry: '../../../dist/packages-dist/forms/index.js',
dest: '../../../dist/packages-dist/forms/bundles/forms.umd.js',
format: 'umd',
moduleName: 'ng.forms',
globals: {
@ -12,8 +12,5 @@ export default {
'rxjs/observable/PromiseObservable': 'Rx', // this is wrong, but this stuff has changed in rxjs b.6 so we need to fix it when we update.
'rxjs/operator/toPromise': 'Rx.Observable.prototype',
'rxjs/Observable': 'Rx'
},
plugins: [
// nodeResolve({ jsnext: true, main: true }),
]
}
}

View File

@ -1,31 +0,0 @@
{
"compilerOptions": {
"baseUrl": ".",
"declaration": true,
"stripInternal": true,
"experimentalDecorators": true,
"module": "commonjs",
"moduleResolution": "node",
"outDir": "../../../dist/packages-dist/forms/",
"paths": {
"@angular/core": ["../../../dist/packages-dist/core/"],
"@angular/core/testing": ["../../../dist/packages-dist/core/testing"],
"@angular/common": ["../../../dist/packages-dist/common"],
"@angular/common/testing": ["../../../dist/packages-dist/common/testing"],
"@angular/compiler": ["../../../dist/packages-dist/compiler"],
"@angular/compiler/testing": ["../../../dist/packages-dist/compiler/testing"]
},
"rootDir": ".",
"sourceMap": true,
"inlineSources": true,
"lib": ["es6", "dom"],
"target": "es5"
},
"files": [
"index.ts",
"../../../node_modules/zone.js/dist/zone.js.d.ts"
],
"angularCompilerOptions": {
"strictMetadataEmit": true
}
}

View File

@ -6,7 +6,7 @@
"experimentalDecorators": true,
"module": "es2015",
"moduleResolution": "node",
"outDir": "../../../dist/packages-dist/forms/esm",
"outDir": "../../../dist/packages-dist/forms",
"paths": {
"@angular/core": ["../../../dist/packages-dist/core"],
"@angular/core/testing": ["../../../dist/packages-dist/core/testing"],
@ -18,7 +18,9 @@
"rootDir": ".",
"sourceMap": true,
"inlineSources": true,
"target": "es2015"
"target": "es5",
"skipLibCheck": true,
"lib": ["es2015", "dom"]
},
"files": [
"index.ts",