Skip to content

Commit

Permalink
docs(packages): add api-extractor to public packages (#4747)
Browse files Browse the repository at this point in the history
* docs(packages): add api-extractor to public packages

* docs(abort-controller): add api-extractor to abort-controller
  • Loading branch information
MYoung25 authored May 23, 2023
1 parent 1982984 commit 20cda3f
Show file tree
Hide file tree
Showing 54 changed files with 145 additions and 9 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ module.exports = {
// Uses the recommended rules from the @typescript-eslint/eslint-plugin
"plugin:@typescript-eslint/recommended",
],
plugins: ["@typescript-eslint", "simple-import-sort", "eslint-plugin-sort-export-all"],
plugins: ["@typescript-eslint", "simple-import-sort", "eslint-plugin-sort-export-all", "eslint-plugin-tsdoc"],
rules: {
/** Turn off strict enforcement */
"@typescript-eslint/ban-types": "off",
Expand All @@ -23,6 +23,7 @@ module.exports = {

/** Warnings */
"@typescript-eslint/no-namespace": "warn",
"tsdoc/syntax": "warn",

/** Errors */
"simple-import-sort/imports": "error",
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ benchmark/size/raw

etc/
temp/
temp-packages/
temp-lib/

# Gradle composite build properties
codegen/local.properties
14 changes: 6 additions & 8 deletions api-extractor.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,7 @@
* This would direct API Extractor to embed those types directly in the .d.ts rollup, as if they had been
* local files for library1.
*/
"bundledPackages": [
// "@aws-sdk/types", "@aws-sdk/util-waiter", "@aws-sdk/smithy-client"
],
// "bundledPackages": ["@aws-sdk/types", "@aws-sdk/util-waiter", "@aws-sdk/smithy-client", "@aws-smithy/types"],

/**
* Specifies what type of newlines API Extractor should use when writing output files. By default, the output files
Expand Down Expand Up @@ -178,7 +176,7 @@
* SUPPORTED TOKENS: <projectFolder>, <packageName>, <unscopedPackageName>
* DEFAULT VALUE: "<projectFolder>/temp/"
*/
"reportTempFolder": "./temp/"
"reportTempFolder": "./temp/",

/**
* Whether "forgotten exports" should be included in the API report file. Forgotten exports are declarations
Expand All @@ -187,7 +185,7 @@
*
* DEFAULT VALUE: "false"
*/
// "includeForgottenExports": false
"includeForgottenExports": true
},

/**
Expand Down Expand Up @@ -217,7 +215,7 @@
*
* DEFAULT VALUE: "false"
*/
// "includeForgottenExports": false,
// "includeForgottenExports": true

/**
* The base URL where the project's source code can be viewed on a website such as GitHub or
Expand All @@ -243,7 +241,7 @@
/**
* (REQUIRED) Whether to generate the .d.ts rollup file.
*/
"enabled": true
"enabled": false,

/**
* Specifies the output path for a .d.ts rollup file to be generated without any trimming.
Expand All @@ -257,7 +255,7 @@
* SUPPORTED TOKENS: <projectFolder>, <packageName>, <unscopedPackageName>
* DEFAULT VALUE: "<projectFolder>/dist/<unscopedPackageName>.d.ts"
*/
// "untrimmedFilePath": "<projectFolder>/dist/<unscopedPackageName>.d.ts",
"untrimmedFilePath": "./dist/<unscopedPackageName>.d.ts"

/**
* Specifies the output path for a .d.ts rollup file to be generated with trimming for an "alpha" release.
Expand Down
10 changes: 10 additions & 0 deletions api-extractor.packages.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": "./api-extractor.json",
"docModel": {
"apiJsonFilePath": "./temp-packages/<unscopedPackageName>.api.json"
},
"apiReport": {
"reportFolder": "./temp-packages/",
"reportTempFolder": "./temp-packages/"
}
}
4 changes: 4 additions & 0 deletions packages/abort-controller/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/abort-controller/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/cloudfront-signer/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/cloudfront-signer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/credential-providers/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/credential-providers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"keywords": [
Expand Down
4 changes: 4 additions & 0 deletions packages/fetch-http-handler/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/fetch-http-handler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --coverage && karma start karma.conf.js"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/hash-node/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/hash-node/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/middleware-bucket-endpoint/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/middleware-bucket-endpoint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/middleware-endpoint/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/middleware-endpoint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --passWithNoTests",
"test:integration": "jest -c jest.config.integ.js"
},
Expand Down
4 changes: 4 additions & 0 deletions packages/middleware-retry/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/middleware-retry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest",
"test:integration": "jest -c jest.config.integ.js"
},
Expand Down
4 changes: 4 additions & 0 deletions packages/middleware-stack/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/middleware-stack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest",
"test:integration": "jest -c jest.config.integ.js --passWithNoTests"
},
Expand Down
4 changes: 4 additions & 0 deletions packages/node-http-handler/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/node-http-handler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --coverage"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/polly-request-presigner/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/polly-request-presigner/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/rds-signer/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/rds-signer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"engines": {
Expand Down
4 changes: 4 additions & 0 deletions packages/s3-presigned-post/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/s3-presigned-post/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest",
"test:e2e": "jest -c jest.config.e2e.js"
},
Expand Down
4 changes: 4 additions & 0 deletions packages/s3-request-presigner/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/s3-request-presigner/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/shared-ini-file-loader/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/shared-ini-file-loader/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/signature-v4-crt/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/signature-v4-crt/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --coverage"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/signature-v4-multi-region/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/signature-v4-multi-region/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/signature-v4/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/signature-v4/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --coverage"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/smithy-client/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/smithy-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest --passWithNoTests"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/token-providers/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/token-providers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"keywords": [
Expand Down
4 changes: 4 additions & 0 deletions packages/types/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/types/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "tsc -p tsconfig.test.json"
},
"author": {
Expand Down
4 changes: 4 additions & 0 deletions packages/util-create-request/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/util-create-request/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/util-dynamodb/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
1 change: 1 addition & 0 deletions packages/util-dynamodb/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"build:types": "tsc -p tsconfig.types.json",
"build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
"clean": "rimraf ./dist-* && rimraf *.tsbuildinfo",
"extract:docs": "api-extractor run --local",
"test": "jest"
},
"main": "./dist-cjs/index.js",
Expand Down
4 changes: 4 additions & 0 deletions packages/util-retry/api-extractor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"extends": "../../api-extractor.packages.json",
"mainEntryPointFilePath": "./dist-types/index.d.ts"
}
Loading

0 comments on commit 20cda3f

Please sign in to comment.