diff --git a/docs/en/UI/Angular/Service-Proxies.md b/docs/en/UI/Angular/Service-Proxies.md index dc8433f7de..6cd79505c2 100644 --- a/docs/en/UI/Angular/Service-Proxies.md +++ b/docs/en/UI/Angular/Service-Proxies.md @@ -18,7 +18,9 @@ Run the following command in the **root folder** of the angular application: abp generate-proxy -t ng ``` -The command without any parameters creates proxies only for your own application's services and places them in your default Angular application. There are several parameters you may use to modify this behavior. See the [CLI documentation](../../CLI) for details. +### Note +- If you're utilizing NX, be aware that the Angular schematics-based ABP package may not work as expected. Instead, there's a specialized package for NX-based repositories named @abp/nx.generators. We recommend using this generator for your package. For detailed instructions and more information, refer to this section. +- The command without any parameters creates proxies for your own application's services only and places them in your default Angular application. There are several parameters you may use to modify this behavior. See the [Details](#abp-nx-proxy-generator). The generated files will be placed in a folder called `proxy` at the root of the target project. @@ -140,6 +142,26 @@ export class BookComponent implements OnInit { > Please [see this article](https://github.com/abpframework/abp/blob/dev/docs/en/Blog-Posts/2020-09-07%20Angular-Service-Proxies/POST.md) to learn more about service proxies. + +### ABP NX Proxy Generator + For projects that utilize NX, the @abp/nx.generators package offers seamless integration. Essentially, this package serves as a wrapper specifically tailored for NX-based repositories + **Installation** +To incorporate this package into your project, run the following command: +```bash +yarn add @abp/nx.generators +``` +### Usage +To use the generator, execute the following command: + +```bash +yarn nx generate @abp/nx.generators:generate-proxy +// or +yarn nx g @abp/nx.generators:generate-proxy +``` + +**Note:** The parameters you'd use with this generator are consistent with the standard ABP proxy generator. + + ### Known Limitations When you run a project on Visual Studio using IIS Express as the web server, there will be no remote access to your endpoints. This is the default behavior of IIS Express since it explicitly protects you from the security risks of running over the network. However, that will cause the proxy generator to fail because it needs a response from the `/api/abp/api-definition` endpoint. You may serve your endpoints via Kestrel to avoid this. Running `dotnet run` in your command line (at your project folder) will do that for you.