mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
build: add flatModuleIndexRedirect to generated metadata redirect (#5512)
This commit is contained in:
@@ -3,7 +3,11 @@ import {join} from 'path';
|
||||
|
||||
/** Creates a metadata file that re-exports the metadata bundle inside of the typings. */
|
||||
export function createMetadataReexportFile(packageDir: string, packageName: string) {
|
||||
const metadataReExport =
|
||||
`{"__symbolic":"module","version":3,"metadata":{},"exports":[{"from":"./typings/index"}]}`;
|
||||
const metadataReExport = `{
|
||||
"__symbolic":"module",
|
||||
"version":3,"metadata":{},
|
||||
"exports":[{"from":"./typings/index"}],
|
||||
"flatModuleIndexRedirect": true
|
||||
}`;
|
||||
writeFileSync(join(packageDir, `${packageName}.metadata.json`), metadataReExport, 'utf-8');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user