@azure-tools/typespec-ts 0.55.0 → 0.55.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/README.md +24 -19
- package/dist/src/context-manager.d.ts +19 -2
- package/dist/src/context-manager.d.ts.map +1 -1
- package/dist/src/context-manager.js +21 -0
- package/dist/src/context-manager.js.map +1 -1
- package/dist/src/framework/declaration.d.ts.map +1 -1
- package/dist/src/framework/declaration.js +6 -20
- package/dist/src/framework/declaration.js.map +1 -1
- package/dist/src/framework/hooks/sdk-types.d.ts +9 -0
- package/dist/src/framework/hooks/sdk-types.d.ts.map +1 -1
- package/dist/src/framework/hooks/sdk-types.js +14 -1
- package/dist/src/framework/hooks/sdk-types.js.map +1 -1
- package/dist/src/framework/source-file-batch.d.ts +35 -0
- package/dist/src/framework/source-file-batch.d.ts.map +1 -0
- package/dist/src/framework/source-file-batch.js +128 -0
- package/dist/src/framework/source-file-batch.js.map +1 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +84 -66
- package/dist/src/index.js.map +1 -1
- package/dist/src/{rlc-common/interfaces.d.ts → interfaces.d.ts} +12 -14
- package/dist/src/interfaces.d.ts.map +1 -0
- package/dist/src/interfaces.js.map +1 -0
- package/dist/src/lib.d.ts +17 -5
- package/dist/src/lib.d.ts.map +1 -1
- package/dist/src/lib.js +24 -17
- package/dist/src/lib.js.map +1 -1
- package/dist/src/meta-tree.d.ts +4 -4
- package/dist/src/meta-tree.d.ts.map +1 -1
- package/dist/src/metadata/build-api-extractor-config.d.ts +6 -0
- package/dist/src/metadata/build-api-extractor-config.d.ts.map +1 -0
- package/dist/src/metadata/build-api-extractor-config.js.map +1 -0
- package/dist/src/metadata/build-changelog-file.d.ts +6 -0
- package/dist/src/metadata/build-changelog-file.d.ts.map +1 -0
- package/dist/src/metadata/build-changelog-file.js.map +1 -0
- package/dist/src/metadata/build-es-lint-config.d.ts +6 -0
- package/dist/src/metadata/build-es-lint-config.d.ts.map +1 -0
- package/dist/src/metadata/build-es-lint-config.js.map +1 -0
- package/dist/src/metadata/build-license-file.d.ts.map +1 -0
- package/dist/src/metadata/build-license-file.js.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-package-file.d.ts +3 -3
- package/dist/src/metadata/build-package-file.d.ts.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-package-file.js +1 -1
- package/dist/src/metadata/build-package-file.js.map +1 -0
- package/dist/src/metadata/build-readme-file.d.ts +11 -0
- package/dist/src/metadata/build-readme-file.d.ts.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-readme-file.js +16 -69
- package/dist/src/metadata/build-readme-file.js.map +1 -0
- package/dist/src/metadata/build-sample-env-file.d.ts +6 -0
- package/dist/src/metadata/build-sample-env-file.d.ts.map +1 -0
- package/dist/src/metadata/build-sample-env-file.js.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-test-config.d.ts +3 -3
- package/dist/src/metadata/build-test-config.d.ts.map +1 -0
- package/dist/src/metadata/build-test-config.js.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-ts-config.d.ts +13 -7
- package/dist/src/metadata/build-ts-config.d.ts.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-ts-config.js +24 -8
- package/dist/src/metadata/build-ts-config.js.map +1 -0
- package/dist/src/metadata/build-vitest-config.d.ts +6 -0
- package/dist/src/metadata/build-vitest-config.d.ts.map +1 -0
- package/dist/src/metadata/build-vitest-config.js.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/build-warp-config.d.ts +2 -2
- package/dist/src/metadata/build-warp-config.d.ts.map +1 -0
- package/dist/src/metadata/build-warp-config.js.map +1 -0
- package/dist/src/metadata/package-json/azure-package-common.d.ts.map +1 -0
- package/dist/src/metadata/package-json/azure-package-common.js.map +1 -0
- package/dist/src/metadata/package-json/build-azure-monorepo-package.d.ts.map +1 -0
- package/dist/src/{rlc-common/metadata → metadata}/package-json/build-azure-monorepo-package.js +1 -1
- package/dist/src/metadata/package-json/build-azure-monorepo-package.js.map +1 -0
- package/dist/src/metadata/package-json/package-common.d.ts.map +1 -0
- package/dist/src/metadata/package-json/package-common.js.map +1 -0
- package/dist/src/metadata/render-template.d.ts +24 -0
- package/dist/src/metadata/render-template.d.ts.map +1 -0
- package/dist/src/metadata/render-template.js +148 -0
- package/dist/src/metadata/render-template.js.map +1 -0
- package/dist/src/metadata/test/build-recorded-client.d.ts +6 -0
- package/dist/src/metadata/test/build-recorded-client.d.ts.map +1 -0
- package/dist/src/metadata/test/build-recorded-client.js +8 -0
- package/dist/src/metadata/test/build-recorded-client.js.map +1 -0
- package/dist/src/metadata/test/build-sample-test.d.ts +6 -0
- package/dist/src/metadata/test/build-sample-test.d.ts.map +1 -0
- package/dist/src/metadata/test/build-sample-test.js +8 -0
- package/dist/src/metadata/test/build-sample-test.js.map +1 -0
- package/dist/src/metadata/test/build-snippets.d.ts +6 -0
- package/dist/src/metadata/test/build-snippets.d.ts.map +1 -0
- package/dist/src/{rlc-common → metadata}/test/build-snippets.js +3 -5
- package/dist/src/metadata/test/build-snippets.js.map +1 -0
- package/dist/src/metadata/test/template.d.ts +4 -0
- package/dist/src/metadata/test/template.d.ts.map +1 -0
- package/dist/src/metadata/test/template.js +100 -0
- package/dist/src/metadata/test/template.js.map +1 -0
- package/dist/src/metadata/utils.d.ts +3 -0
- package/dist/src/metadata/utils.d.ts.map +1 -0
- package/dist/src/metadata/utils.js.map +1 -0
- package/dist/src/modular/build-classical-client.d.ts.map +1 -1
- package/dist/src/modular/build-classical-client.js +11 -11
- package/dist/src/modular/build-classical-client.js.map +1 -1
- package/dist/src/modular/build-classical-operation-groups.d.ts.map +1 -1
- package/dist/src/modular/build-classical-operation-groups.js +3 -3
- package/dist/src/modular/build-classical-operation-groups.js.map +1 -1
- package/dist/src/modular/build-client-context.d.ts.map +1 -1
- package/dist/src/modular/build-client-context.js +7 -7
- package/dist/src/modular/build-client-context.js.map +1 -1
- package/dist/src/modular/build-modular-options.js +3 -3
- package/dist/src/modular/build-modular-options.js.map +1 -1
- package/dist/src/modular/build-operations.d.ts.map +1 -1
- package/dist/src/modular/build-operations.js +6 -6
- package/dist/src/modular/build-operations.js.map +1 -1
- package/dist/src/modular/build-project-files.d.ts.map +1 -1
- package/dist/src/modular/build-project-files.js +4 -4
- package/dist/src/modular/build-project-files.js.map +1 -1
- package/dist/src/modular/build-restore-poller.d.ts.map +1 -1
- package/dist/src/modular/build-restore-poller.js +3 -3
- package/dist/src/modular/build-restore-poller.js.map +1 -1
- package/dist/src/modular/build-root-index.d.ts.map +1 -1
- package/dist/src/modular/build-root-index.js +42 -14
- package/dist/src/modular/build-root-index.js.map +1 -1
- package/dist/src/modular/build-subpath-index.d.ts.map +1 -1
- package/dist/src/modular/build-subpath-index.js +17 -4
- package/dist/src/modular/build-subpath-index.js.map +1 -1
- package/dist/src/modular/emit-models-options.d.ts.map +1 -1
- package/dist/src/modular/emit-models-options.js +3 -3
- package/dist/src/modular/emit-models-options.js.map +1 -1
- package/dist/src/modular/emit-models.d.ts +1 -1
- package/dist/src/modular/emit-models.d.ts.map +1 -1
- package/dist/src/modular/emit-models.js +32 -25
- package/dist/src/modular/emit-models.js.map +1 -1
- package/dist/src/modular/emit-samples.d.ts.map +1 -1
- package/dist/src/modular/emit-samples.js +5 -5
- package/dist/src/modular/emit-samples.js.map +1 -1
- package/dist/src/modular/emit-tests.d.ts.map +1 -1
- package/dist/src/modular/emit-tests.js +1 -1
- package/dist/src/modular/emit-tests.js.map +1 -1
- package/dist/src/modular/helpers/classical-operation-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/classical-operation-helpers.js +11 -11
- package/dist/src/modular/helpers/classical-operation-helpers.js.map +1 -1
- package/dist/src/modular/helpers/client-helpers.d.ts +6 -1
- package/dist/src/modular/helpers/client-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/client-helpers.js +18 -14
- package/dist/src/modular/helpers/client-helpers.js.map +1 -1
- package/dist/src/modular/helpers/example-value-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/example-value-helpers.js +2 -2
- package/dist/src/modular/helpers/example-value-helpers.js.map +1 -1
- package/dist/src/modular/helpers/naming-helpers.d.ts +1 -1
- package/dist/src/modular/helpers/naming-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/naming-helpers.js +2 -2
- package/dist/src/modular/helpers/naming-helpers.js.map +1 -1
- package/dist/src/modular/helpers/operation-helpers.d.ts +4 -4
- package/dist/src/modular/helpers/operation-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/operation-helpers.js +25 -26
- package/dist/src/modular/helpers/operation-helpers.js.map +1 -1
- package/dist/src/modular/helpers/type-helpers.d.ts.map +1 -1
- package/dist/src/modular/helpers/type-helpers.js +1 -1
- package/dist/src/modular/helpers/type-helpers.js.map +1 -1
- package/dist/src/modular/interfaces.d.ts +4 -4
- package/dist/src/modular/interfaces.d.ts.map +1 -1
- package/dist/src/modular/serialization/build-deserializer-function.d.ts.map +1 -1
- package/dist/src/modular/serialization/build-deserializer-function.js +2 -2
- package/dist/src/modular/serialization/build-deserializer-function.js.map +1 -1
- package/dist/src/modular/serialization/build-serializer-function.d.ts.map +1 -1
- package/dist/src/modular/serialization/build-serializer-function.js +2 -2
- package/dist/src/modular/serialization/build-serializer-function.js.map +1 -1
- package/dist/src/modular/serialization/build-xml-serializer-function.d.ts.map +1 -1
- package/dist/src/modular/serialization/build-xml-serializer-function.js +1 -1
- package/dist/src/modular/serialization/build-xml-serializer-function.js.map +1 -1
- package/dist/src/modular/type-expressions/get-enum-expression.js +1 -1
- package/dist/src/modular/type-expressions/get-enum-expression.js.map +1 -1
- package/dist/src/modular/type-expressions/get-nullable-expression.js +1 -1
- package/dist/src/modular/type-expressions/get-nullable-expression.js.map +1 -1
- package/dist/src/modular/type-expressions/get-type-expression.d.ts.map +1 -1
- package/dist/src/modular/type-expressions/get-type-expression.js +3 -3
- package/dist/src/modular/type-expressions/get-type-expression.js.map +1 -1
- package/dist/src/transform/transform-api-version-info.d.ts +1 -1
- package/dist/src/transform/transform-api-version-info.d.ts.map +1 -1
- package/dist/src/transform/transform-api-version-info.js +4 -3
- package/dist/src/transform/transform-api-version-info.js.map +1 -1
- package/dist/src/transform/{transfrom-rlc-options.d.ts → transform-client-options.d.ts} +3 -3
- package/dist/src/transform/transform-client-options.d.ts.map +1 -0
- package/dist/src/transform/{transfrom-rlc-options.js → transform-client-options.js} +9 -13
- package/dist/src/transform/transform-client-options.js.map +1 -0
- package/dist/src/transform/transform-helper-function-details.d.ts +1 -1
- package/dist/src/transform/transform-helper-function-details.d.ts.map +1 -1
- package/dist/src/transform/transform-helper-function-details.js +4 -4
- package/dist/src/transform/transform-helper-function-details.js.map +1 -1
- package/dist/src/transform/transform-parameters.d.ts +1 -1
- package/dist/src/transform/transform-parameters.d.ts.map +1 -1
- package/dist/src/transform/transform-parameters.js +11 -11
- package/dist/src/transform/transform-parameters.js.map +1 -1
- package/dist/src/transform/transform-paths.d.ts +1 -1
- package/dist/src/transform/transform-paths.d.ts.map +1 -1
- package/dist/src/transform/transform-paths.js +5 -4
- package/dist/src/transform/transform-paths.js.map +1 -1
- package/dist/src/transform/transform-responses.d.ts +1 -1
- package/dist/src/transform/transform-responses.d.ts.map +1 -1
- package/dist/src/transform/transform-responses.js +19 -18
- package/dist/src/transform/transform-responses.js.map +1 -1
- package/dist/src/transform/transform-schemas.js +5 -5
- package/dist/src/transform/transform-schemas.js.map +1 -1
- package/dist/src/transform/transform-telemetry-info.d.ts +1 -1
- package/dist/src/transform/transform-telemetry-info.d.ts.map +1 -1
- package/dist/src/transform/transform-telemetry-info.js +2 -2
- package/dist/src/transform/transform-telemetry-info.js.map +1 -1
- package/dist/src/transform/transform.d.ts +2 -2
- package/dist/src/transform/transform.d.ts.map +1 -1
- package/dist/src/transform/transform.js +9 -10
- package/dist/src/transform/transform.js.map +1 -1
- package/dist/src/utils/api-version-util.d.ts.map +1 -0
- package/dist/src/utils/api-version-util.js.map +1 -0
- package/dist/src/utils/client-utils.d.ts +5 -5
- package/dist/src/utils/client-utils.d.ts.map +1 -1
- package/dist/src/utils/client-utils.js +10 -10
- package/dist/src/utils/client-utils.js.map +1 -1
- package/dist/src/utils/cross-language-def.d.ts.map +1 -1
- package/dist/src/utils/cross-language-def.js +3 -3
- package/dist/src/utils/cross-language-def.js.map +1 -1
- package/dist/src/utils/emit-util.d.ts +2 -2
- package/dist/src/utils/emit-util.d.ts.map +1 -1
- package/dist/src/utils/emit-util.js +2 -2
- package/dist/src/utils/emit-util.js.map +1 -1
- package/dist/src/utils/imports-util.d.ts.map +1 -0
- package/dist/src/{rlc-common/helpers → utils}/imports-util.js +6 -6
- package/dist/src/utils/imports-util.js.map +1 -0
- package/dist/src/utils/interfaces.d.ts +3 -4
- package/dist/src/utils/interfaces.d.ts.map +1 -1
- package/dist/src/utils/model-utils.d.ts +1 -1
- package/dist/src/utils/model-utils.d.ts.map +1 -1
- package/dist/src/utils/model-utils.js +4 -2
- package/dist/src/utils/model-utils.js.map +1 -1
- package/dist/src/{rlc-common/helpers → utils}/name-constructors.d.ts +2 -2
- package/dist/src/utils/name-constructors.d.ts.map +1 -0
- package/dist/src/utils/name-constructors.js.map +1 -0
- package/dist/src/utils/name-utils.d.ts.map +1 -0
- package/dist/src/utils/name-utils.js.map +1 -0
- package/dist/src/utils/namespace-utils.js +4 -4
- package/dist/src/utils/namespace-utils.js.map +1 -1
- package/dist/src/utils/operation-helpers.d.ts +16 -0
- package/dist/src/utils/operation-helpers.d.ts.map +1 -0
- package/dist/src/utils/operation-helpers.js.map +1 -0
- package/dist/src/utils/operation-util.d.ts +2 -2
- package/dist/src/utils/operation-util.d.ts.map +1 -1
- package/dist/src/utils/operation-util.js +17 -18
- package/dist/src/utils/operation-util.js.map +1 -1
- package/dist/src/utils/parameter-utils.d.ts +1 -1
- package/dist/src/utils/parameter-utils.d.ts.map +1 -1
- package/dist/src/utils/parameter-utils.js +2 -4
- package/dist/src/utils/parameter-utils.js.map +1 -1
- package/dist/src/{rlc-common/helpers → utils}/schema-helpers.d.ts +2 -2
- package/dist/src/utils/schema-helpers.d.ts.map +1 -0
- package/dist/src/utils/schema-helpers.js.map +1 -0
- package/dist/src/utils/type-util.d.ts.map +1 -0
- package/dist/src/utils/type-util.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +36 -46
- package/src/context-manager.ts +25 -2
- package/src/framework/declaration.ts +8 -20
- package/src/framework/hooks/sdk-types.ts +15 -1
- package/src/framework/source-file-batch.ts +140 -0
- package/src/index.ts +104 -107
- package/src/{rlc-common/interfaces.ts → interfaces.ts} +14 -16
- package/src/lib.ts +43 -23
- package/src/meta-tree.ts +4 -4
- package/src/{rlc-common/metadata → metadata}/build-api-extractor-config.ts +2 -2
- package/src/{rlc-common/metadata → metadata}/build-changelog-file.ts +3 -3
- package/src/{rlc-common/metadata → metadata}/build-es-lint-config.ts +2 -2
- package/src/{rlc-common/metadata → metadata}/build-package-file.ts +6 -6
- package/src/{rlc-common/metadata → metadata}/build-readme-file.ts +25 -99
- package/src/{rlc-common/metadata → metadata}/build-sample-env-file.ts +2 -2
- package/src/{rlc-common/metadata → metadata}/build-test-config.ts +4 -4
- package/src/{rlc-common/metadata → metadata}/build-ts-config.ts +28 -11
- package/src/{rlc-common/metadata → metadata}/build-vitest-config.ts +2 -2
- package/src/{rlc-common/metadata → metadata}/build-warp-config.ts +2 -2
- package/src/{rlc-common/metadata → metadata}/package-json/build-azure-monorepo-package.ts +1 -1
- package/src/metadata/render-template.ts +202 -0
- package/src/metadata/test/build-recorded-client.ts +9 -0
- package/src/metadata/test/build-sample-test.ts +9 -0
- package/src/{rlc-common → metadata}/test/build-snippets.ts +5 -7
- package/src/metadata/test/template.ts +101 -0
- package/src/{rlc-common/metadata → metadata}/utils.ts +2 -2
- package/src/modular/build-classical-client.ts +11 -15
- package/src/modular/build-classical-operation-groups.ts +3 -3
- package/src/modular/build-client-context.ts +7 -7
- package/src/modular/build-modular-options.ts +3 -3
- package/src/modular/build-operations.ts +6 -6
- package/src/modular/build-project-files.ts +4 -5
- package/src/modular/build-restore-poller.ts +3 -3
- package/src/modular/build-root-index.ts +57 -19
- package/src/modular/build-subpath-index.ts +26 -5
- package/src/modular/emit-models-options.ts +3 -3
- package/src/modular/emit-models.ts +32 -26
- package/src/modular/emit-samples.ts +5 -5
- package/src/modular/emit-tests.ts +1 -1
- package/src/modular/helpers/classical-operation-helpers.ts +11 -11
- package/src/modular/helpers/client-helpers.ts +19 -16
- package/src/modular/helpers/example-value-helpers.ts +2 -2
- package/src/modular/helpers/naming-helpers.ts +2 -2
- package/src/modular/helpers/operation-helpers.ts +27 -27
- package/src/modular/helpers/type-helpers.ts +1 -1
- package/src/modular/interfaces.ts +4 -4
- package/src/modular/serialization/build-deserializer-function.ts +2 -2
- package/src/modular/serialization/build-serializer-function.ts +2 -2
- package/src/modular/serialization/build-xml-serializer-function.ts +1 -1
- package/src/modular/type-expressions/get-enum-expression.ts +1 -1
- package/src/modular/type-expressions/get-nullable-expression.ts +1 -1
- package/src/modular/type-expressions/get-type-expression.ts +3 -3
- package/src/transform/transform-api-version-info.ts +4 -10
- package/src/transform/{transfrom-rlc-options.ts → transform-client-options.ts} +12 -22
- package/src/transform/transform-helper-function-details.ts +5 -5
- package/src/transform/transform-parameters.ts +12 -12
- package/src/transform/transform-paths.ts +5 -12
- package/src/transform/transform-responses.ts +19 -19
- package/src/transform/transform-schemas.ts +5 -5
- package/src/transform/transform-telemetry-info.ts +3 -3
- package/src/transform/transform.ts +13 -18
- package/src/utils/client-utils.ts +11 -11
- package/src/utils/cross-language-def.ts +3 -3
- package/src/utils/emit-util.ts +3 -3
- package/src/{rlc-common/helpers → utils}/imports-util.ts +6 -6
- package/src/utils/interfaces.ts +3 -4
- package/src/utils/model-utils.ts +7 -8
- package/src/{rlc-common/helpers → utils}/name-constructors.ts +2 -2
- package/src/utils/namespace-utils.ts +4 -4
- package/src/{rlc-common/helpers → utils}/operation-helpers.ts +12 -12
- package/src/utils/operation-util.ts +19 -33
- package/src/utils/parameter-utils.ts +2 -4
- package/src/{rlc-common/helpers → utils}/schema-helpers.ts +2 -2
- package/dist/src/rlc-common/helpers/api-version-util.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/api-version-util.js.map +0 -1
- package/dist/src/rlc-common/helpers/imports-util.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/imports-util.js.map +0 -1
- package/dist/src/rlc-common/helpers/name-constructors.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/name-constructors.js.map +0 -1
- package/dist/src/rlc-common/helpers/name-utils.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/name-utils.js.map +0 -1
- package/dist/src/rlc-common/helpers/operation-helpers.d.ts +0 -16
- package/dist/src/rlc-common/helpers/operation-helpers.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/operation-helpers.js.map +0 -1
- package/dist/src/rlc-common/helpers/schema-helpers.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/schema-helpers.js.map +0 -1
- package/dist/src/rlc-common/helpers/type-util.d.ts.map +0 -1
- package/dist/src/rlc-common/helpers/type-util.js.map +0 -1
- package/dist/src/rlc-common/index.d.ts +0 -23
- package/dist/src/rlc-common/index.d.ts.map +0 -1
- package/dist/src/rlc-common/index.js +0 -25
- package/dist/src/rlc-common/index.js.map +0 -1
- package/dist/src/rlc-common/interfaces.d.ts.map +0 -1
- package/dist/src/rlc-common/interfaces.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-api-extractor-config.d.ts +0 -6
- package/dist/src/rlc-common/metadata/build-api-extractor-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-api-extractor-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-changelog-file.d.ts +0 -6
- package/dist/src/rlc-common/metadata/build-changelog-file.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-changelog-file.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-es-lint-config.d.ts +0 -6
- package/dist/src/rlc-common/metadata/build-es-lint-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-es-lint-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-license-file.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-license-file.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-package-file.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-package-file.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-readme-file.d.ts +0 -11
- package/dist/src/rlc-common/metadata/build-readme-file.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-readme-file.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-sample-env-file.d.ts +0 -6
- package/dist/src/rlc-common/metadata/build-sample-env-file.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-sample-env-file.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-test-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-test-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-ts-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-ts-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-vitest-config.d.ts +0 -6
- package/dist/src/rlc-common/metadata/build-vitest-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-vitest-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/build-warp-config.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/build-warp-config.js.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/azure-package-common.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/azure-package-common.js.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/build-azure-monorepo-package.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/build-azure-monorepo-package.js.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/package-common.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/package-json/package-common.js.map +0 -1
- package/dist/src/rlc-common/metadata/utils.d.ts +0 -3
- package/dist/src/rlc-common/metadata/utils.d.ts.map +0 -1
- package/dist/src/rlc-common/metadata/utils.js.map +0 -1
- package/dist/src/rlc-common/static/paginate-content.d.ts +0 -2
- package/dist/src/rlc-common/static/paginate-content.d.ts.map +0 -1
- package/dist/src/rlc-common/static/paginate-content.js +0 -345
- package/dist/src/rlc-common/static/paginate-content.js.map +0 -1
- package/dist/src/rlc-common/static/polling-content.d.ts +0 -2
- package/dist/src/rlc-common/static/polling-content.d.ts.map +0 -1
- package/dist/src/rlc-common/static/polling-content.js +0 -225
- package/dist/src/rlc-common/static/polling-content.js.map +0 -1
- package/dist/src/rlc-common/static/sample-template.d.ts +0 -2
- package/dist/src/rlc-common/static/sample-template.d.ts.map +0 -1
- package/dist/src/rlc-common/static/sample-template.js +0 -56
- package/dist/src/rlc-common/static/sample-template.js.map +0 -1
- package/dist/src/rlc-common/static/serialize-helper.d.ts +0 -6
- package/dist/src/rlc-common/static/serialize-helper.d.ts.map +0 -1
- package/dist/src/rlc-common/static/serialize-helper.js +0 -31
- package/dist/src/rlc-common/static/serialize-helper.js.map +0 -1
- package/dist/src/rlc-common/test/build-karma-config.d.ts +0 -6
- package/dist/src/rlc-common/test/build-karma-config.d.ts.map +0 -1
- package/dist/src/rlc-common/test/build-karma-config.js +0 -11
- package/dist/src/rlc-common/test/build-karma-config.js.map +0 -1
- package/dist/src/rlc-common/test/build-recorded-client.d.ts +0 -6
- package/dist/src/rlc-common/test/build-recorded-client.d.ts.map +0 -1
- package/dist/src/rlc-common/test/build-recorded-client.js +0 -14
- package/dist/src/rlc-common/test/build-recorded-client.js.map +0 -1
- package/dist/src/rlc-common/test/build-sample-test.d.ts +0 -6
- package/dist/src/rlc-common/test/build-sample-test.d.ts.map +0 -1
- package/dist/src/rlc-common/test/build-sample-test.js +0 -11
- package/dist/src/rlc-common/test/build-sample-test.js.map +0 -1
- package/dist/src/rlc-common/test/build-snippets.d.ts +0 -6
- package/dist/src/rlc-common/test/build-snippets.d.ts.map +0 -1
- package/dist/src/rlc-common/test/build-snippets.js.map +0 -1
- package/dist/src/rlc-common/test/template.d.ts +0 -5
- package/dist/src/rlc-common/test/template.d.ts.map +0 -1
- package/dist/src/rlc-common/test/template.js +0 -227
- package/dist/src/rlc-common/test/template.js.map +0 -1
- package/dist/src/transform/transfrom-rlc-options.d.ts.map +0 -1
- package/dist/src/transform/transfrom-rlc-options.js.map +0 -1
- package/src/rlc-common/index.ts +0 -25
- package/src/rlc-common/static/paginate-content.ts +0 -345
- package/src/rlc-common/static/polling-content.ts +0 -225
- package/src/rlc-common/static/sample-template.ts +0 -56
- package/src/rlc-common/static/serialize-helper.ts +0 -34
- package/src/rlc-common/test/build-karma-config.ts +0 -12
- package/src/rlc-common/test/build-recorded-client.ts +0 -15
- package/src/rlc-common/test/build-sample-test.ts +0 -12
- package/src/rlc-common/test/template.ts +0 -229
- /package/dist/src/{rlc-common/interfaces.js → interfaces.js} +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-api-extractor-config.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-changelog-file.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-es-lint-config.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-license-file.d.ts +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-license-file.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-sample-env-file.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-test-config.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-vitest-config.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/build-warp-config.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/package-json/azure-package-common.d.ts +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/package-json/azure-package-common.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/package-json/build-azure-monorepo-package.d.ts +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/package-json/package-common.d.ts +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/package-json/package-common.js +0 -0
- /package/dist/src/{rlc-common/metadata → metadata}/utils.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/api-version-util.d.ts +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/api-version-util.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/imports-util.d.ts +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/name-constructors.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/name-utils.d.ts +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/name-utils.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/operation-helpers.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/schema-helpers.js +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/type-util.d.ts +0 -0
- /package/dist/src/{rlc-common/helpers → utils}/type-util.js +0 -0
- /package/src/{rlc-common/metadata → metadata}/build-license-file.ts +0 -0
- /package/src/{rlc-common/metadata → metadata}/package-json/azure-package-common.ts +0 -0
- /package/src/{rlc-common/metadata → metadata}/package-json/package-common.ts +0 -0
- /package/src/{rlc-common/helpers → utils}/api-version-util.ts +0 -0
- /package/src/{rlc-common/helpers → utils}/name-utils.ts +0 -0
- /package/src/{rlc-common/helpers → utils}/type-util.ts +0 -0
package/src/index.ts
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
resolvePath,
|
|
11
11
|
type CompilerHost,
|
|
12
12
|
} from "@typespec/compiler";
|
|
13
|
-
import { provideContext, useContext } from "./context-manager.js";
|
|
13
|
+
import { clearContexts, provideContext, useContext } from "./context-manager.js";
|
|
14
14
|
import { buildRootIndex, buildSubClientIndexFile } from "./modular/build-root-index.js";
|
|
15
15
|
import {
|
|
16
16
|
AzureCoreDependencies,
|
|
@@ -31,37 +31,6 @@ import {
|
|
|
31
31
|
UrlTemplateHelpers,
|
|
32
32
|
XmlHelpers,
|
|
33
33
|
} from "./modular/static-helpers-metadata.js";
|
|
34
|
-
import {
|
|
35
|
-
RLCModel,
|
|
36
|
-
RLCOptions,
|
|
37
|
-
buildApiExtractorConfig,
|
|
38
|
-
buildChangelogFile,
|
|
39
|
-
buildEsLintConfig,
|
|
40
|
-
buildLicenseFile,
|
|
41
|
-
buildPackageFile,
|
|
42
|
-
buildReadmeFile,
|
|
43
|
-
buildRecordedClientFile,
|
|
44
|
-
buildSampleEnvFile,
|
|
45
|
-
buildSampleTest,
|
|
46
|
-
buildSnippets,
|
|
47
|
-
buildTestBrowserTsConfig,
|
|
48
|
-
buildTestNodeTsConfig,
|
|
49
|
-
buildTsConfig,
|
|
50
|
-
buildTsLintConfig,
|
|
51
|
-
buildTsSampleConfig,
|
|
52
|
-
buildTsSnippetsConfig,
|
|
53
|
-
buildTsSrcBrowserConfig,
|
|
54
|
-
buildTsSrcCjsConfig,
|
|
55
|
-
buildTsSrcEsmConfig,
|
|
56
|
-
buildTsSrcReactNativeConfig,
|
|
57
|
-
buildVitestConfig,
|
|
58
|
-
buildWarpConfig,
|
|
59
|
-
getClientName,
|
|
60
|
-
hasClientNameChanged,
|
|
61
|
-
hasUnexpectedHelper,
|
|
62
|
-
updatePackageFile,
|
|
63
|
-
updateReadmeFile,
|
|
64
|
-
} from "./rlc-common/index.js";
|
|
65
34
|
import { emitContentByBuilder } from "./utils/emit-util.js";
|
|
66
35
|
import { clearDirectory, emptyDir, pathExists } from "./utils/file-system-utils.js";
|
|
67
36
|
import { GenerationDirDetail, SdkContext } from "./utils/interfaces.js";
|
|
@@ -74,9 +43,37 @@ import {
|
|
|
74
43
|
} from "@azure-tools/typespec-client-generator-core";
|
|
75
44
|
import { Project } from "ts-morph";
|
|
76
45
|
import { provideBinder } from "./framework/hooks/binder.js";
|
|
77
|
-
import { provideSdkTypes } from "./framework/hooks/sdk-types.js";
|
|
46
|
+
import { provideSdkTypes, resetSdkTypesState } from "./framework/hooks/sdk-types.js";
|
|
78
47
|
import { loadStaticHelpers } from "./framework/load-static-helpers.js";
|
|
48
|
+
import { ClientModel, ClientOptions } from "./interfaces.js";
|
|
79
49
|
import { EmitterOptions } from "./lib.js";
|
|
50
|
+
import { buildApiExtractorConfig } from "./metadata/build-api-extractor-config.js";
|
|
51
|
+
import { buildChangelogFile } from "./metadata/build-changelog-file.js";
|
|
52
|
+
import { buildEsLintConfig } from "./metadata/build-es-lint-config.js";
|
|
53
|
+
import { buildLicenseFile } from "./metadata/build-license-file.js";
|
|
54
|
+
import { buildPackageFile, updatePackageFile } from "./metadata/build-package-file.js";
|
|
55
|
+
import {
|
|
56
|
+
buildReadmeFile,
|
|
57
|
+
hasClientNameChanged,
|
|
58
|
+
updateReadmeFile,
|
|
59
|
+
} from "./metadata/build-readme-file.js";
|
|
60
|
+
import { buildSampleEnvFile } from "./metadata/build-sample-env-file.js";
|
|
61
|
+
import { buildTestBrowserTsConfig, buildTestNodeTsConfig } from "./metadata/build-test-config.js";
|
|
62
|
+
import {
|
|
63
|
+
buildTsConfig,
|
|
64
|
+
buildTsLintConfig,
|
|
65
|
+
buildTsSampleConfig,
|
|
66
|
+
buildTsSnippetsConfig,
|
|
67
|
+
buildTsSrcBrowserConfig,
|
|
68
|
+
buildTsSrcCjsConfig,
|
|
69
|
+
buildTsSrcEsmConfig,
|
|
70
|
+
buildTsSrcReactNativeConfig,
|
|
71
|
+
} from "./metadata/build-ts-config.js";
|
|
72
|
+
import { buildVitestConfig } from "./metadata/build-vitest-config.js";
|
|
73
|
+
import { buildWarpConfig } from "./metadata/build-warp-config.js";
|
|
74
|
+
import { buildRecordedClientFile } from "./metadata/test/build-recorded-client.js";
|
|
75
|
+
import { buildSampleTest } from "./metadata/test/build-sample-test.js";
|
|
76
|
+
import { buildSnippets } from "./metadata/test/build-snippets.js";
|
|
80
77
|
import { buildClassicalClient } from "./modular/build-classical-client.js";
|
|
81
78
|
import { buildClassicOperationFiles } from "./modular/build-classical-operation-groups.js";
|
|
82
79
|
import { buildClientContext, getClientContextPath } from "./modular/build-client-context.js";
|
|
@@ -93,13 +90,9 @@ import { emitTests } from "./modular/emit-tests.js";
|
|
|
93
90
|
import { getClassicalClientName } from "./modular/helpers/naming-helpers.js";
|
|
94
91
|
import { ModularEmitterOptions } from "./modular/interfaces.js";
|
|
95
92
|
import { packageUsesXmlSerialization } from "./modular/serialization/build-xml-serializer-function.js";
|
|
96
|
-
import {
|
|
97
|
-
import {
|
|
98
|
-
import {
|
|
99
|
-
getClientHierarchyMap,
|
|
100
|
-
getModularClientOptions,
|
|
101
|
-
getRLCClients,
|
|
102
|
-
} from "./utils/client-utils.js";
|
|
93
|
+
import { transformClientOptions } from "./transform/transform-client-options.js";
|
|
94
|
+
import { transformClientModel } from "./transform/transform.js";
|
|
95
|
+
import { getClientHierarchyMap, getClientModuleInfo, getClients } from "./utils/client-utils.js";
|
|
103
96
|
import { generateCrossLanguageDefinitionFile } from "./utils/cross-language-def.js";
|
|
104
97
|
|
|
105
98
|
export * from "./lib.js";
|
|
@@ -128,11 +121,9 @@ export async function $onEmit(context: EmitContext) {
|
|
|
128
121
|
|
|
129
122
|
// Enrich the dpg context with path detail and common options
|
|
130
123
|
await enrichDpgContext();
|
|
131
|
-
const
|
|
124
|
+
const resolvedEmitterOptions = dpgContext.emitterOptions ?? {};
|
|
132
125
|
|
|
133
|
-
|
|
134
|
-
const serviceNameToRlcModelsMap: Map<string, RLCModel> = new Map<string, RLCModel>();
|
|
135
|
-
provideContext("rlcMetaTree", new Map());
|
|
126
|
+
provideContext("clientTypeMetaTree", new Map());
|
|
136
127
|
provideContext("symbolMap", new Map());
|
|
137
128
|
provideContext("outputProject", outputProject);
|
|
138
129
|
provideContext("emitContext", {
|
|
@@ -151,13 +142,13 @@ export async function $onEmit(context: EmitContext) {
|
|
|
151
142
|
...PlatformTypeHelpers,
|
|
152
143
|
...CloudSettingHelpers,
|
|
153
144
|
...XmlHelpers,
|
|
154
|
-
...(
|
|
155
|
-
...(
|
|
145
|
+
...(resolvedEmitterOptions.generateTest ? CreateRecorderHelpers : {}),
|
|
146
|
+
...(resolvedEmitterOptions.enableStorageCompat ? StorageCompatHelpers : {}),
|
|
156
147
|
},
|
|
157
148
|
{
|
|
158
|
-
sourcesDir: dpgContext.generationPathDetail?.
|
|
149
|
+
sourcesDir: dpgContext.generationPathDetail?.sourcesDir,
|
|
159
150
|
rootDir: dpgContext.generationPathDetail?.rootDir,
|
|
160
|
-
options:
|
|
151
|
+
options: resolvedEmitterOptions,
|
|
161
152
|
program,
|
|
162
153
|
host,
|
|
163
154
|
packageRoot: emitterPackageRoot,
|
|
@@ -178,20 +169,16 @@ export async function $onEmit(context: EmitContext) {
|
|
|
178
169
|
});
|
|
179
170
|
provideSdkTypes(dpgContext);
|
|
180
171
|
|
|
181
|
-
const rlcCodeModels: RLCModel[] = [];
|
|
182
172
|
let modularEmitterOptions: ModularEmitterOptions;
|
|
183
173
|
// 1. Clear sources folder
|
|
184
174
|
await clearSrcFolder();
|
|
185
|
-
// 2.
|
|
186
|
-
// TODO: skip this step in modular once modular generator is sufficiently decoupled
|
|
187
|
-
await buildRLCCodeModels();
|
|
188
|
-
// 3. Clear samples-dev folder if generateSample is true
|
|
175
|
+
// 2. Clear samples-dev folder if generateSample is true
|
|
189
176
|
await clearSamplesDevFolder();
|
|
190
177
|
|
|
191
|
-
//
|
|
192
|
-
await
|
|
178
|
+
// 3. Generate sources
|
|
179
|
+
await generateSources();
|
|
193
180
|
|
|
194
|
-
//
|
|
181
|
+
// 4. Generate metadata and test files
|
|
195
182
|
function getTypespecTsVersion(context: EmitContext): string | undefined {
|
|
196
183
|
const emitterMetadata = context.program.emitters.find(
|
|
197
184
|
(emitter) => emitter.metadata.name === "@azure-tools/typespec-ts",
|
|
@@ -201,11 +188,20 @@ export async function $onEmit(context: EmitContext) {
|
|
|
201
188
|
|
|
202
189
|
await generateMetadataAndTest(dpgContext);
|
|
203
190
|
|
|
191
|
+
// Release the emitter's process-wide singleton state now that this emit has
|
|
192
|
+
// finished writing output. Without this, the context manager keeps the whole
|
|
193
|
+
// previous program graph (compiler `EmitContext`/`Program`, TCGC `SdkContext`,
|
|
194
|
+
// ts-morph `Project`, binder, …) reachable until the next emit overwrites it.
|
|
195
|
+
// Clearing here lets it be collected between emits, which matters for hosts
|
|
196
|
+
// that run many emits in one process (test suites, benchmarks, watch mode).
|
|
197
|
+
clearContexts();
|
|
198
|
+
resetSdkTypesState();
|
|
199
|
+
|
|
204
200
|
async function enrichDpgContext() {
|
|
205
201
|
const generationPathDetail: GenerationDirDetail = await calculateGenerationDir();
|
|
206
202
|
dpgContext.generationPathDetail = generationPathDetail;
|
|
207
203
|
dpgContext.allServiceNamespaces = listAllServiceNamespaces(dpgContext);
|
|
208
|
-
const options:
|
|
204
|
+
const options: ClientOptions = transformClientOptions(emitterOptions, dpgContext);
|
|
209
205
|
emitterOptions["generate-sample"] = options.generateSample;
|
|
210
206
|
// clear output folder if needed
|
|
211
207
|
if (options.clearOutputFolder) {
|
|
@@ -219,7 +215,7 @@ export async function $onEmit(context: EmitContext) {
|
|
|
219
215
|
options.generateTest =
|
|
220
216
|
options.generateTest === true ||
|
|
221
217
|
(options.generateTest === undefined && (!hasTestFolder || options.azureArm));
|
|
222
|
-
dpgContext.
|
|
218
|
+
dpgContext.emitterOptions = options;
|
|
223
219
|
}
|
|
224
220
|
|
|
225
221
|
async function calculateGenerationDir(): Promise<GenerationDirDetail> {
|
|
@@ -236,18 +232,12 @@ export async function $onEmit(context: EmitContext) {
|
|
|
236
232
|
return {
|
|
237
233
|
rootDir: projectRoot,
|
|
238
234
|
metadataDir: projectRoot,
|
|
239
|
-
|
|
240
|
-
modularSourcesDir: sourcesRoot,
|
|
235
|
+
sourcesDir: sourcesRoot,
|
|
241
236
|
};
|
|
242
237
|
}
|
|
243
238
|
|
|
244
239
|
async function clearSrcFolder() {
|
|
245
|
-
await emptyDir(
|
|
246
|
-
host,
|
|
247
|
-
dpgContext.generationPathDetail?.modularSourcesDir ??
|
|
248
|
-
dpgContext.generationPathDetail?.rlcSourcesDir ??
|
|
249
|
-
"",
|
|
250
|
-
);
|
|
240
|
+
await emptyDir(host, dpgContext.generationPathDetail?.sourcesDir ?? "");
|
|
251
241
|
}
|
|
252
242
|
|
|
253
243
|
async function clearSamplesDevFolder() {
|
|
@@ -262,32 +252,30 @@ export async function $onEmit(context: EmitContext) {
|
|
|
262
252
|
}
|
|
263
253
|
}
|
|
264
254
|
|
|
265
|
-
async function
|
|
266
|
-
const
|
|
255
|
+
async function buildClientCodeModels(): Promise<ClientModel[]> {
|
|
256
|
+
const models: ClientModel[] = [];
|
|
257
|
+
const clients = getClients(dpgContext);
|
|
267
258
|
for (const client of clients) {
|
|
268
|
-
|
|
269
|
-
rlcCodeModels.push(rlcModels);
|
|
270
|
-
const serviceName = client.services[0]?.name ?? "Unknown";
|
|
271
|
-
serviceNameToRlcModelsMap.set(serviceName, rlcModels);
|
|
272
|
-
needUnexpectedHelper.set(getClientName(rlcModels), hasUnexpectedHelper(rlcModels));
|
|
259
|
+
models.push(await transformClientModel(client, dpgContext));
|
|
273
260
|
}
|
|
261
|
+
return models;
|
|
274
262
|
}
|
|
275
263
|
|
|
276
|
-
async function
|
|
277
|
-
const
|
|
264
|
+
async function generateSources() {
|
|
265
|
+
const sourcesRoot = dpgContext.generationPathDetail?.sourcesDir ?? "src";
|
|
278
266
|
const project = useContext("outputProject");
|
|
279
|
-
modularEmitterOptions = transformModularEmitterOptions(dpgContext,
|
|
267
|
+
modularEmitterOptions = transformModularEmitterOptions(dpgContext, sourcesRoot, {
|
|
280
268
|
casing: "camel",
|
|
281
269
|
});
|
|
282
270
|
|
|
283
|
-
emitLoggerFile(modularEmitterOptions,
|
|
271
|
+
emitLoggerFile(modularEmitterOptions, sourcesRoot);
|
|
284
272
|
|
|
285
|
-
const rootIndexFile = project.createSourceFile(`${
|
|
273
|
+
const rootIndexFile = project.createSourceFile(`${sourcesRoot}/index.ts`, "", {
|
|
286
274
|
overwrite: true,
|
|
287
275
|
});
|
|
288
276
|
|
|
289
|
-
emitTypes(dpgContext, { sourceRoot:
|
|
290
|
-
emitNonModelResponseTypes(dpgContext, { sourceRoot:
|
|
277
|
+
emitTypes(dpgContext, { sourceRoot: sourcesRoot });
|
|
278
|
+
emitNonModelResponseTypes(dpgContext, { sourceRoot: sourcesRoot });
|
|
291
279
|
buildSubpathIndexFile(modularEmitterOptions, "models", undefined, {
|
|
292
280
|
recursive: true,
|
|
293
281
|
});
|
|
@@ -302,7 +290,7 @@ export async function $onEmit(context: EmitContext) {
|
|
|
302
290
|
buildOperationFiles(dpgContext, subClient, modularEmitterOptions);
|
|
303
291
|
buildClientContext(dpgContext, subClient, modularEmitterOptions);
|
|
304
292
|
buildRestorePoller(dpgContext, subClient, modularEmitterOptions);
|
|
305
|
-
if (dpgContext.
|
|
293
|
+
if (dpgContext.emitterOptions?.hierarchyClient) {
|
|
306
294
|
buildSubpathIndexFile(modularEmitterOptions, "api", subClient, {
|
|
307
295
|
exportIndex: false,
|
|
308
296
|
recursive: true,
|
|
@@ -320,24 +308,24 @@ export async function $onEmit(context: EmitContext) {
|
|
|
320
308
|
exportIndex: true,
|
|
321
309
|
interfaceOnly: true,
|
|
322
310
|
});
|
|
323
|
-
const { subfolder } =
|
|
311
|
+
const { subfolder } = getClientModuleInfo(subClient);
|
|
324
312
|
// Generate index file for clients with subfolders (multi-client scenarios and nested clients)
|
|
325
313
|
if (subfolder) {
|
|
326
314
|
buildSubClientIndexFile(dpgContext, subClient, modularEmitterOptions);
|
|
327
315
|
}
|
|
328
316
|
buildRootIndex(dpgContext, modularEmitterOptions, rootIndexFile, subClient);
|
|
329
317
|
}
|
|
330
|
-
//
|
|
318
|
+
// Sample generation is enabled only when the modular generator actually emits
|
|
319
|
+
// samples. Reset the baseline here, then re-enable it below if any are emitted.
|
|
320
|
+
dpgContext.emitterOptions!.generateSample = false;
|
|
331
321
|
if (emitterOptions["generate-sample"] === true) {
|
|
332
322
|
const samples = emitSamples(dpgContext);
|
|
333
|
-
// Refine the rlc sample generation logic
|
|
334
|
-
// TODO: remember to remove this out when RLC is splitted from Modular
|
|
335
323
|
if (samples.length > 0) {
|
|
336
|
-
dpgContext.
|
|
324
|
+
dpgContext.emitterOptions!.generateSample = true;
|
|
337
325
|
}
|
|
338
326
|
}
|
|
339
327
|
|
|
340
|
-
binder.resolveAllReferences(
|
|
328
|
+
binder.resolveAllReferences(sourcesRoot, dpgContext.generationPathDetail?.rootDir);
|
|
341
329
|
if (program.compilerOptions.noEmit || program.hasError()) {
|
|
342
330
|
return;
|
|
343
331
|
}
|
|
@@ -382,17 +370,18 @@ export async function $onEmit(context: EmitContext) {
|
|
|
382
370
|
|
|
383
371
|
async function generateMetadataAndTest(context: SdkContext) {
|
|
384
372
|
const project = useContext("outputProject");
|
|
385
|
-
|
|
373
|
+
const clientCodeModels = await buildClientCodeModels();
|
|
374
|
+
if (clientCodeModels.length === 0 || !clientCodeModels[0]) {
|
|
386
375
|
return;
|
|
387
376
|
}
|
|
388
|
-
const
|
|
389
|
-
const option = dpgContext.
|
|
377
|
+
const clientModel: ClientModel = clientCodeModels[0];
|
|
378
|
+
const option = dpgContext.emitterOptions!;
|
|
390
379
|
// When generateMetadata is explicitly false and the sources are generated
|
|
391
380
|
// into a path ending with "generated" (e.g. src/generated), this package
|
|
392
381
|
// has a manual convenience layer. Skip all metadata/test file generation
|
|
393
382
|
// to avoid unexpected modifications to files like package.json, README.md,
|
|
394
383
|
// warp.config.yml, and snippets.spec.ts. metadata.json is still updated.
|
|
395
|
-
const sourcesDir = dpgContext.generationPathDetail?.
|
|
384
|
+
const sourcesDir = dpgContext.generationPathDetail?.sourcesDir ?? "";
|
|
396
385
|
const hasManualConvenienceLayer = getBaseFileName(sourcesDir) === "generated";
|
|
397
386
|
// Generate metadata
|
|
398
387
|
const existingPackageFilePath = joinPaths(
|
|
@@ -426,7 +415,7 @@ export async function $onEmit(context: EmitContext) {
|
|
|
426
415
|
|
|
427
416
|
//TODO Need consider multi-client cases
|
|
428
417
|
for (const subClient of dpgContext.sdkPackage.clients) {
|
|
429
|
-
|
|
418
|
+
clientModel.libraryName = subClient.name;
|
|
430
419
|
}
|
|
431
420
|
|
|
432
421
|
if (shouldGenerateMetadata) {
|
|
@@ -473,12 +462,12 @@ export async function $onEmit(context: EmitContext) {
|
|
|
473
462
|
// Generate warp.config.yml for Azure monorepo ESM packages
|
|
474
463
|
commonBuilders.push((model) => buildWarpConfig(model, modularPackageInfo));
|
|
475
464
|
commonBuilders.push(buildTsConfig);
|
|
476
|
-
commonBuilders.push(buildTsSrcEsmConfig);
|
|
477
|
-
commonBuilders.push(buildTsSrcBrowserConfig);
|
|
465
|
+
commonBuilders.push(() => buildTsSrcEsmConfig(modularPackageInfo["exports"]));
|
|
466
|
+
commonBuilders.push(() => buildTsSrcBrowserConfig(modularPackageInfo["exports"]));
|
|
478
467
|
if (option.generateReactNativeTarget) {
|
|
479
|
-
commonBuilders.push(buildTsSrcReactNativeConfig);
|
|
468
|
+
commonBuilders.push(() => buildTsSrcReactNativeConfig(modularPackageInfo["exports"]));
|
|
480
469
|
}
|
|
481
|
-
commonBuilders.push(buildTsSrcCjsConfig);
|
|
470
|
+
commonBuilders.push(() => buildTsSrcCjsConfig(modularPackageInfo["exports"]));
|
|
482
471
|
if (option.generateSample) {
|
|
483
472
|
commonBuilders.push(buildTsSampleConfig);
|
|
484
473
|
}
|
|
@@ -496,7 +485,7 @@ export async function $onEmit(context: EmitContext) {
|
|
|
496
485
|
await emitContentByBuilder(
|
|
497
486
|
program,
|
|
498
487
|
commonBuilders,
|
|
499
|
-
|
|
488
|
+
clientModel,
|
|
500
489
|
dpgContext.generationPathDetail?.metadataDir,
|
|
501
490
|
);
|
|
502
491
|
|
|
@@ -525,8 +514,8 @@ export async function $onEmit(context: EmitContext) {
|
|
|
525
514
|
}),
|
|
526
515
|
};
|
|
527
516
|
|
|
528
|
-
// Always update package.json (adds #platform/* imports)
|
|
529
|
-
//
|
|
517
|
+
// Always update package.json (adds #platform/* imports) along with
|
|
518
|
+
// exports, clientContextPaths and LRO deps.
|
|
530
519
|
{
|
|
531
520
|
// Read package.json content via host and pass parsed object
|
|
532
521
|
const pkgSourceFile = await host.readFile(existingPackageFilePath);
|
|
@@ -536,30 +525,38 @@ export async function $onEmit(context: EmitContext) {
|
|
|
536
525
|
} catch {
|
|
537
526
|
packageInfo = {};
|
|
538
527
|
}
|
|
539
|
-
updateBuilders.push((model:
|
|
528
|
+
updateBuilders.push((model: ClientModel) =>
|
|
540
529
|
updatePackageFile(model, packageInfo, modularPackageInfo),
|
|
541
530
|
);
|
|
542
531
|
}
|
|
543
532
|
|
|
544
533
|
// Update warp.config.yml for Azure monorepo packages
|
|
545
|
-
updateBuilders.push((model:
|
|
534
|
+
updateBuilders.push((model: ClientModel) => buildWarpConfig(model, modularPackageInfo));
|
|
535
|
+
|
|
536
|
+
// Re-sync tsconfig.src.*.json `include` with the warp exports
|
|
537
|
+
updateBuilders.push(() => buildTsSrcEsmConfig(modularPackageInfo["exports"]));
|
|
538
|
+
updateBuilders.push(() => buildTsSrcBrowserConfig(modularPackageInfo["exports"]));
|
|
539
|
+
if (option.generateReactNativeTarget) {
|
|
540
|
+
updateBuilders.push(() => buildTsSrcReactNativeConfig(modularPackageInfo["exports"]));
|
|
541
|
+
}
|
|
542
|
+
updateBuilders.push(() => buildTsSrcCjsConfig(modularPackageInfo["exports"]));
|
|
546
543
|
|
|
547
544
|
// If the client name changed, regenerate the README and snippets completely;
|
|
548
545
|
// otherwise update only the API reference link in-place.
|
|
549
546
|
if (hasReadmeFile) {
|
|
550
547
|
const readmeSourceFile = await host.readFile(existingReadmeFilePath);
|
|
551
548
|
const existingReadmeContent = readmeSourceFile.text;
|
|
552
|
-
const clientNameChanged = hasClientNameChanged(
|
|
549
|
+
const clientNameChanged = hasClientNameChanged(clientModel, existingReadmeContent);
|
|
553
550
|
updateBuilders.push(
|
|
554
551
|
clientNameChanged
|
|
555
552
|
? buildReadmeFile
|
|
556
|
-
: (model:
|
|
553
|
+
: (model: ClientModel) => updateReadmeFile(model, existingReadmeContent),
|
|
557
554
|
);
|
|
558
555
|
|
|
559
556
|
// Regenerate snippets.spec.ts only when the client name changed
|
|
560
557
|
if (clientNameChanged) {
|
|
561
558
|
for (const subClient of dpgContext.sdkPackage.clients) {
|
|
562
|
-
updateBuilders.push((model:
|
|
559
|
+
updateBuilders.push((model: ClientModel) =>
|
|
563
560
|
buildSnippets(model, getClassicalClientName(subClient)),
|
|
564
561
|
);
|
|
565
562
|
}
|
|
@@ -570,14 +567,14 @@ export async function $onEmit(context: EmitContext) {
|
|
|
570
567
|
await emitContentByBuilder(
|
|
571
568
|
program,
|
|
572
569
|
updateBuilders,
|
|
573
|
-
|
|
570
|
+
clientModel,
|
|
574
571
|
dpgContext.generationPathDetail?.metadataDir,
|
|
575
572
|
);
|
|
576
573
|
}
|
|
577
574
|
await emitContentByBuilder(
|
|
578
575
|
program,
|
|
579
576
|
buildMetadataJson,
|
|
580
|
-
|
|
577
|
+
clientModel,
|
|
581
578
|
dpgContext.generationPathDetail?.metadataDir,
|
|
582
579
|
);
|
|
583
580
|
|
|
@@ -586,7 +583,7 @@ export async function $onEmit(context: EmitContext) {
|
|
|
586
583
|
await emitContentByBuilder(
|
|
587
584
|
program,
|
|
588
585
|
[buildRecordedClientFile, buildSampleTest],
|
|
589
|
-
|
|
586
|
+
clientModel,
|
|
590
587
|
dpgContext.generationPathDetail?.metadataDir,
|
|
591
588
|
);
|
|
592
589
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
// Copyright (c) Microsoft Corporation.
|
|
2
2
|
// Licensed under the MIT License.
|
|
3
|
-
export interface
|
|
3
|
+
export interface ClientModel {
|
|
4
4
|
libraryName: string;
|
|
5
5
|
srcPath: string;
|
|
6
6
|
paths: Paths;
|
|
7
7
|
importInfo: ImportInfo;
|
|
8
|
-
options?:
|
|
8
|
+
options?: ClientOptions;
|
|
9
9
|
schemas: Schema[];
|
|
10
10
|
apiVersionInfo?: ApiVersionInfo;
|
|
11
11
|
parameters?: OperationParameter[];
|
|
@@ -13,8 +13,8 @@ export interface RLCModel {
|
|
|
13
13
|
helperDetails?: HelperFunctionDetails;
|
|
14
14
|
urlInfo?: UrlInfo;
|
|
15
15
|
telemetryOptions?: TelemetryInfo;
|
|
16
|
-
sampleGroups?:
|
|
17
|
-
|
|
16
|
+
sampleGroups?: SampleGroup[];
|
|
17
|
+
sourceDir?: string;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
export interface ImportInfo {
|
|
@@ -28,10 +28,10 @@ export type ImportType =
|
|
|
28
28
|
/**inner models' imports for parameter and response */
|
|
29
29
|
| "parameter"
|
|
30
30
|
| "response"
|
|
31
|
-
| "
|
|
31
|
+
| "index"
|
|
32
32
|
| "modularModel"
|
|
33
|
-
| "
|
|
34
|
-
| "
|
|
33
|
+
| "clientFactory"
|
|
34
|
+
| "clientDefinition"
|
|
35
35
|
/**common third party imports */
|
|
36
36
|
| "restClient"
|
|
37
37
|
| "coreAuth"
|
|
@@ -60,18 +60,18 @@ export interface ImportMetadata {
|
|
|
60
60
|
/**
|
|
61
61
|
* A group of samples in operation_id level and they are used to generate in a sample file
|
|
62
62
|
*/
|
|
63
|
-
export interface
|
|
63
|
+
export interface SampleGroup {
|
|
64
64
|
filename: string;
|
|
65
65
|
clientPackageName: string;
|
|
66
66
|
defaultFactoryName: string;
|
|
67
|
-
samples:
|
|
67
|
+
samples: SampleDetail[];
|
|
68
68
|
importedTypes?: string[];
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
/**
|
|
72
72
|
* An independent sample detail and it will be wrapped as a func
|
|
73
73
|
*/
|
|
74
|
-
export interface
|
|
74
|
+
export interface SampleDetail {
|
|
75
75
|
/**
|
|
76
76
|
* metadata for comments
|
|
77
77
|
*/
|
|
@@ -190,7 +190,7 @@ export interface OperationLroDetail {
|
|
|
190
190
|
precedence?: number;
|
|
191
191
|
}
|
|
192
192
|
|
|
193
|
-
export interface
|
|
193
|
+
export interface ClientOptions {
|
|
194
194
|
/**
|
|
195
195
|
* Whether to include response headers in the generated response types. If true, the generated response types will include headers as properties.
|
|
196
196
|
*/
|
|
@@ -223,7 +223,6 @@ export interface RLCOptions {
|
|
|
223
223
|
generateTest?: boolean;
|
|
224
224
|
generateSample?: boolean;
|
|
225
225
|
azureOutputDirectory?: string;
|
|
226
|
-
isTypeSpecTest?: boolean;
|
|
227
226
|
serviceInfo?: ServiceInfo;
|
|
228
227
|
azureArm?: boolean;
|
|
229
228
|
enableOperationGroup?: boolean;
|
|
@@ -234,7 +233,6 @@ export interface RLCOptions {
|
|
|
234
233
|
clearOutputFolder?: boolean;
|
|
235
234
|
ignorePropertyNameNormalize?: boolean;
|
|
236
235
|
ignoreEnumMemberNameNormalize?: boolean;
|
|
237
|
-
compatibilityQueryMultiFormat?: boolean;
|
|
238
236
|
typespecTitleMap?: Record<string, string>;
|
|
239
237
|
hasSubscriptionId?: boolean;
|
|
240
238
|
compatibilityLro?: boolean;
|
|
@@ -357,8 +355,8 @@ export interface ParameterMetadatas {
|
|
|
357
355
|
export interface ParameterBodyMetadata {
|
|
358
356
|
/**
|
|
359
357
|
* In case of formData we'd get multiple properties in body marked as partialBody
|
|
360
|
-
* If yes,
|
|
361
|
-
* usually false in typespec source because
|
|
358
|
+
* If yes, the emitter would prepare the whole part shape;
|
|
359
|
+
* usually false in typespec source because the emitter doesn't have to prepare the whole part shape
|
|
362
360
|
*/
|
|
363
361
|
isPartialBody?: boolean;
|
|
364
362
|
body?: ParameterBodySchema[];
|
|
@@ -398,7 +396,7 @@ export type ResponseHeaderSchema = Schema;
|
|
|
398
396
|
export type ResponseBodySchema = Schema;
|
|
399
397
|
|
|
400
398
|
export type ContentBuilder = {
|
|
401
|
-
(model:
|
|
399
|
+
(model: ClientModel): File | File[] | undefined;
|
|
402
400
|
};
|
|
403
401
|
|
|
404
402
|
export type SampleParameterPosition = "client" | "path" | "method";
|
package/src/lib.ts
CHANGED
|
@@ -3,9 +3,24 @@
|
|
|
3
3
|
|
|
4
4
|
import { createTypeSpecLibrary, JSONSchemaType, paramMessage } from "@typespec/compiler";
|
|
5
5
|
import { Options } from "prettier";
|
|
6
|
-
import { PackageDetails } from "./
|
|
6
|
+
import { PackageDetails } from "./interfaces.js";
|
|
7
7
|
|
|
8
8
|
export interface EmitterOptions {
|
|
9
|
+
/**
|
|
10
|
+
* Use this flag if you would like to generate the sdk only for a specific version.
|
|
11
|
+
* Also accepts values `latest` and `all`, or a map from service namespace full name to version for multi-service packages.
|
|
12
|
+
*/
|
|
13
|
+
"api-version"?: string | Record<string, string>;
|
|
14
|
+
/**
|
|
15
|
+
* Specifies the directory where the emitter will look for example files.
|
|
16
|
+
* Defaults to an `examples` directory located at the project root.
|
|
17
|
+
*/
|
|
18
|
+
"examples-dir"?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Specifies the namespace you want to override for namespaces set in the spec.
|
|
21
|
+
* With this config, all namespace for the spec types will default to it.
|
|
22
|
+
*/
|
|
23
|
+
namespace?: string;
|
|
9
24
|
/**
|
|
10
25
|
* Indicates whether to include response headers in the generated response type for modular operations.
|
|
11
26
|
* When set to true, modular operation responses with model or void bodies will have their headers
|
|
@@ -39,7 +54,6 @@ export interface EmitterOptions {
|
|
|
39
54
|
*/
|
|
40
55
|
"generate-test"?: boolean;
|
|
41
56
|
"generate-sample"?: boolean;
|
|
42
|
-
"is-typespec-test"?: boolean;
|
|
43
57
|
"azure-arm"?: boolean;
|
|
44
58
|
"enable-operation-group"?: boolean;
|
|
45
59
|
"enable-model-namespace"?: boolean;
|
|
@@ -49,11 +63,8 @@ export interface EmitterOptions {
|
|
|
49
63
|
"experimental-extensible-enums"?: boolean;
|
|
50
64
|
"clear-output-folder"?: boolean;
|
|
51
65
|
"ignore-property-name-normalize"?: boolean;
|
|
52
|
-
"compatibility-query-multi-format"?: boolean;
|
|
53
66
|
"typespec-title-map"?: Record<string, string>;
|
|
54
67
|
"ignore-enum-member-name-normalize"?: boolean;
|
|
55
|
-
//TODO should remove this after finish the release tool test
|
|
56
|
-
"should-use-pnpm-dep"?: boolean;
|
|
57
68
|
"ignore-nullable-on-optional"?: boolean;
|
|
58
69
|
/**
|
|
59
70
|
* When set to true (default for Azure services), non-model return types (arrays, scalars, enums,
|
|
@@ -82,10 +93,35 @@ export interface EmitterOptions {
|
|
|
82
93
|
"generate-react-native-target"?: boolean;
|
|
83
94
|
}
|
|
84
95
|
|
|
85
|
-
export const
|
|
96
|
+
export const EmitterOptionsSchema: JSONSchemaType<EmitterOptions> = {
|
|
86
97
|
type: "object",
|
|
87
98
|
additionalProperties: true,
|
|
88
99
|
properties: {
|
|
100
|
+
"api-version": {
|
|
101
|
+
oneOf: [
|
|
102
|
+
{ type: "string", nullable: true },
|
|
103
|
+
{
|
|
104
|
+
type: "object",
|
|
105
|
+
additionalProperties: { type: "string" },
|
|
106
|
+
required: [],
|
|
107
|
+
nullable: true,
|
|
108
|
+
},
|
|
109
|
+
],
|
|
110
|
+
description:
|
|
111
|
+
"Use this flag if you would like to generate the sdk only for a specific version. Default value is the latest version. Also accepts values `latest` and `all`. For multi-service packages, provide a map from each service namespace's full name to its desired version; services not listed default to their latest version.",
|
|
112
|
+
} as any,
|
|
113
|
+
"examples-dir": {
|
|
114
|
+
type: "string",
|
|
115
|
+
nullable: true,
|
|
116
|
+
description:
|
|
117
|
+
"Specifies the directory where the emitter will look for example files. If the flag isn't set, the emitter defaults to using an `examples` directory located at the project root.",
|
|
118
|
+
},
|
|
119
|
+
namespace: {
|
|
120
|
+
type: "string",
|
|
121
|
+
nullable: true,
|
|
122
|
+
description:
|
|
123
|
+
"Specifies the namespace you want to override for namespaces set in the spec. With this config, all namespace for the spec types will default to it.",
|
|
124
|
+
},
|
|
89
125
|
"include-headers-in-response": {
|
|
90
126
|
type: "boolean",
|
|
91
127
|
nullable: true,
|
|
@@ -171,11 +207,6 @@ export const RLCOptionsSchema: JSONSchemaType<EmitterOptions> = {
|
|
|
171
207
|
description:
|
|
172
208
|
"Whether to generate sample files, for basic samples of your generated sdks. Defaults to `undefined`. Management packages' default to `true`.",
|
|
173
209
|
},
|
|
174
|
-
"is-typespec-test": {
|
|
175
|
-
type: "boolean",
|
|
176
|
-
nullable: true,
|
|
177
|
-
description: "Internal option for test",
|
|
178
|
-
},
|
|
179
210
|
"azure-arm": {
|
|
180
211
|
type: "boolean",
|
|
181
212
|
nullable: true,
|
|
@@ -234,12 +265,6 @@ export const RLCOptionsSchema: JSONSchemaType<EmitterOptions> = {
|
|
|
234
265
|
description:
|
|
235
266
|
"The emitter has a normalization logic for enum member key, to ignore this normalization, you can set this option to true",
|
|
236
267
|
},
|
|
237
|
-
"compatibility-query-multi-format": {
|
|
238
|
-
type: "boolean",
|
|
239
|
-
nullable: true,
|
|
240
|
-
description:
|
|
241
|
-
"Whether to generate the backward-compatible code for query parameter serialization for array types in RLC. Defaults to `false`",
|
|
242
|
-
},
|
|
243
268
|
"typespec-title-map": {
|
|
244
269
|
type: "object",
|
|
245
270
|
additionalProperties: {
|
|
@@ -258,11 +283,6 @@ export const RLCOptionsSchema: JSONSchemaType<EmitterOptions> = {
|
|
|
258
283
|
"```",
|
|
259
284
|
].join("\n"),
|
|
260
285
|
},
|
|
261
|
-
"should-use-pnpm-dep": {
|
|
262
|
-
type: "boolean",
|
|
263
|
-
nullable: true,
|
|
264
|
-
description: "Internal option for test.",
|
|
265
|
-
},
|
|
266
286
|
"ignore-nullable-on-optional": {
|
|
267
287
|
type: "boolean",
|
|
268
288
|
nullable: true,
|
|
@@ -561,7 +581,7 @@ const libDef = {
|
|
|
561
581
|
},
|
|
562
582
|
},
|
|
563
583
|
emitter: {
|
|
564
|
-
options:
|
|
584
|
+
options: EmitterOptionsSchema,
|
|
565
585
|
},
|
|
566
586
|
} as const;
|
|
567
587
|
|
package/src/meta-tree.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Type } from "@typespec/compiler";
|
|
2
|
-
import { Schema
|
|
2
|
+
import { Schema } from "./interfaces.js";
|
|
3
3
|
|
|
4
|
-
export interface
|
|
5
|
-
|
|
4
|
+
export interface ClientTypeMetadata {
|
|
5
|
+
clientType: Schema;
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
-
export type
|
|
8
|
+
export type ClientTypeMetaTree = Map<Type, ClientTypeMetadata>;
|