-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Typescript][Angular] Fix generated README when using apiModulePrefix #7725
[Typescript][Angular] Fix generated README when using apiModulePrefix #7725
Conversation
d3349a5
to
06d17ef
Compare
import { ApiModule } from 'my-api-path'; | ||
import { ApiModule as OtherApiModule } from 'my-other-api-path'; | ||
import { {{apiModuleClassName}} } from 'my-api-path'; | ||
import { OtherApiModule } from 'my-other-api-path'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please keep the alias example with as
, see #7722 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
This is to ensure that all services are treated as singletons. | ||
|
||
#### Using multiple OpenAPI files / APIs / ApiModules | ||
In order to use multiple `ApiModules` generated from different OpenAPI files, | ||
you can create an alias name when importing the modules | ||
in order to avoid naming conflicts: | ||
you can avoid naming conflicts by configuring `apiModulePrefix` when generating other modules. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please reword to include the case when the prefix cannot be set:
#7722 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've just reverted the wording (but changed it to use {{apiModuleClassName}}
). I think it's best like this. Now only the sample for with-prefixed-module-name
has changed.
@sorohan thanks for your contribution |
2a7b741
to
db16c02
Compare
@sorohan please rebase onto the current master and update the readme for the customized configuration class name |
db16c02
to
48e69e5
Compare
@macjohnny I've rebased it now. I'm not sure what update to the readme you mean. Can you clarify? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
* master: (66 commits) [Typescript][Angular] Fix generated README when using apiModulePrefix (#7725) remove outdated scala files (#7723) [FEAT][TYPESCRIPT-ANGULAR] Add configurationPrefix option to allow generating unique configuration token (#7731) [bug] Fix FILES sort and path provider issue (#7729) better csharp tests (#7727) [go] Improve examples generation (#7576) Fixes #7635: typescript-inversify generator wrongly handles array type parameters (#7636) [Java] Fix import mapping for arrays with reference items of type string (#7182) [Java][Native] Support oneOf/anyOf schemas (#7263) [BUG][Ada] Incorrect client Ada code generated (#7719) add cake, sbt integration (#7713) Use 3.0 spec in documentations, update docs (#7710) remove github.com/antihax/optional from go.sum (#7692) Update junit to newer version (4.13.1) (#7690) [Fix/Dart2] Resolve an exception with status 204 and no body. (#7647) [typescript-angular] pass array as a single JSON string to url query when queryParamObjectFormat=json (fix #7620) (#7649) Add back HttpSigningConfiguration.cs remove HTTPSigningConfiguration.cs add AnyType support to Swift generators (#7644) fix warning, remove trailing spaces (#7659) ...
fixes #7722