Skip to content

Commit

Permalink
RC3.0: Make using API trimming optional (#21285)
Browse files Browse the repository at this point in the history
  • Loading branch information
sonalideshpandemsft authored Jun 4, 2024
1 parent 00fe19a commit 23c2373
Show file tree
Hide file tree
Showing 65 changed files with 2,552 additions and 180 deletions.
6 changes: 3 additions & 3 deletions azure/packages/azure-service-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions common/lib/protocol-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/common/container-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,30 @@ declare function use_old_InterfaceDeclaration_IFluidPackageEnvironment(
use_old_InterfaceDeclaration_IFluidPackageEnvironment(
get_current_InterfaceDeclaration_IFluidPackageEnvironment());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IGenericError": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IGenericError():
TypeOnly<old.IGenericError>;
declare function use_current_InterfaceDeclaration_IGenericError(
use: TypeOnly<current.IGenericError>): void;
use_current_InterfaceDeclaration_IGenericError(
get_old_InterfaceDeclaration_IGenericError());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IGenericError": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IGenericError():
TypeOnly<current.IGenericError>;
declare function use_old_InterfaceDeclaration_IGenericError(
use: TypeOnly<old.IGenericError>): void;
use_old_InterfaceDeclaration_IGenericError(
get_current_InterfaceDeclaration_IGenericError());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken:
Expand Down Expand Up @@ -1214,6 +1238,54 @@ declare function use_old_InterfaceDeclaration_ISnapshotTreeWithBlobContents(
use_old_InterfaceDeclaration_ISnapshotTreeWithBlobContents(
get_current_InterfaceDeclaration_ISnapshotTreeWithBlobContents());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IThrottlingWarning": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IThrottlingWarning():
TypeOnly<old.IThrottlingWarning>;
declare function use_current_InterfaceDeclaration_IThrottlingWarning(
use: TypeOnly<current.IThrottlingWarning>): void;
use_current_InterfaceDeclaration_IThrottlingWarning(
get_old_InterfaceDeclaration_IThrottlingWarning());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IThrottlingWarning": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IThrottlingWarning():
TypeOnly<current.IThrottlingWarning>;
declare function use_old_InterfaceDeclaration_IThrottlingWarning(
use: TypeOnly<old.IThrottlingWarning>): void;
use_old_InterfaceDeclaration_IThrottlingWarning(
get_current_InterfaceDeclaration_IThrottlingWarning());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IUsageError": {"forwardCompat": false}
*/
declare function get_old_InterfaceDeclaration_IUsageError():
TypeOnly<old.IUsageError>;
declare function use_current_InterfaceDeclaration_IUsageError(
use: TypeOnly<current.IUsageError>): void;
use_current_InterfaceDeclaration_IUsageError(
get_old_InterfaceDeclaration_IUsageError());

/*
* Validate back compat by using current type in place of old type
* If breaking change required, add in package.json under typeValidation.broken:
* "InterfaceDeclaration_IUsageError": {"backCompat": false}
*/
declare function get_current_InterfaceDeclaration_IUsageError():
TypeOnly<current.IUsageError>;
declare function use_old_InterfaceDeclaration_IUsageError(
use: TypeOnly<old.IUsageError>): void;
use_old_InterfaceDeclaration_IUsageError(
get_current_InterfaceDeclaration_IUsageError());

/*
* Validate forward compat by using old type in place of current type
* If breaking change required, add in package.json under typeValidation.broken:
Expand Down
6 changes: 3 additions & 3 deletions packages/common/core-interfaces/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/common/core-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/common/driver-definitions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
14 changes: 11 additions & 3 deletions packages/dds/cell/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,20 @@
"type": "module",
"exports": {
".": {
"trimmedAPI": {
"import": {
"types": "./lib/public.d.ts"
},
"require": {
"types": "./dist/public.d.ts"
}
},
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -35,7 +43,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/counter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/map/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/matrix/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/merge-tree/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand Down Expand Up @@ -57,7 +57,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/ordered-collection/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
6 changes: 3 additions & 3 deletions packages/dds/register-collection/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
"exports": {
".": {
"import": {
"types": "./lib/public.d.ts",
"types": "./lib/index.d.ts",
"default": "./lib/index.js"
},
"require": {
"types": "./dist/public.d.ts",
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
}
},
Expand All @@ -45,7 +45,7 @@
}
},
"main": "lib/index.js",
"types": "lib/public.d.ts",
"types": "lib/index.d.ts",
"scripts": {
"api": "fluid-build . --task api",
"api-extractor:commonjs": "flub generate entrypoints --outFileAlpha legacy --outDir ./dist",
Expand Down
Loading

0 comments on commit 23c2373

Please sign in to comment.