parent
4e004f3783
commit
00497437a6
|
@ -122,6 +122,11 @@ describe('@angular/core ng_package', () => {
|
|||
it('should not be processed by tsickle', () => {
|
||||
expect(shx.cat('fesm5/core.js')).not.toContain('@fileoverview added by tsickle');
|
||||
});
|
||||
|
||||
it('should load tslib from external bundle', () => {
|
||||
expect(shx.cat('fesm5/core.js')).not.toContain('function __extends');
|
||||
expect(shx.cat('fesm5/core.js')).toMatch('import {.*__extends');
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ def ng_module(name, tsconfig = None, entry_point = None, **kwargs):
|
|||
entry_point = "public_api.ts"
|
||||
_ng_module(name = name, flat_module_out_file = name, tsconfig = tsconfig, entry_point = entry_point, **kwargs)
|
||||
|
||||
def ng_package(name, readme_md = None, license_banner = None, **kwargs):
|
||||
def ng_package(name, readme_md = None, license_banner = None, globals = {}, **kwargs):
|
||||
if not readme_md:
|
||||
readme_md = "//packages:README.md"
|
||||
if not license_banner:
|
||||
|
@ -55,6 +55,9 @@ def ng_package(name, readme_md = None, license_banner = None, **kwargs):
|
|||
name = name,
|
||||
readme_md = readme_md,
|
||||
license_banner = license_banner,
|
||||
globals = dict(globals, **{
|
||||
"tslib": "tslib"
|
||||
}),
|
||||
replacements = PKG_GROUP_REPLACEMENTS,
|
||||
**kwargs)
|
||||
|
||||
|
|
Loading…
Reference in New Issue