nrwl-nx

Using environment variables in nx based nodejs app

混江龙づ霸主 提交于 2020-12-12 02:53:37
问题 I've setup a project with several nodejs and angular apps inside a nrwl/nx workspace. I'm trying to work with the environment files inside the nodejs apps. I've setup the import like this: import {environment} from './environments/environment'; Then I ran ng serve my-node-app and it shows the environment for non production. Now I tried to do ng serve my-node-app --prod to see how the app works with a production setup - but I get the error: Configuration 'production' could not be found in

Benefits of Angular libraries vs Angular modules in a monorepo? NX architecture

家住魔仙堡 提交于 2020-06-28 08:30:27
问题 I'm wondering what are the benefits of working with libraries rathen than modules in Angular, as nx.dev recommands for an monorepo architecture. I understand the benefits for a npm publishable feature like interfaces that another repo will consume, but why would I want to make a library out of a business related feature, like a homepage, for example : myorg/ ├── apps/ │ ├── todos/ │ └── todos-e2e/ ├── libs/ ├── todos/ ├── home/ <-- why nx recommands making a library here? ├── src/ ├── lib/ ├─

Benefits of Angular libraries vs Angular modules in a monorepo? NX architecture

五迷三道 提交于 2020-06-28 08:30:23
问题 I'm wondering what are the benefits of working with libraries rathen than modules in Angular, as nx.dev recommands for an monorepo architecture. I understand the benefits for a npm publishable feature like interfaces that another repo will consume, but why would I want to make a library out of a business related feature, like a homepage, for example : myorg/ ├── apps/ │ ├── todos/ │ └── todos-e2e/ ├── libs/ ├── todos/ ├── home/ <-- why nx recommands making a library here? ├── src/ ├── lib/ ├─

How can I get the previous commit before a push or merge in GitHub Action workflow?

故事扮演 提交于 2020-05-30 04:11:40
问题 I'm using Nx for monorepo support on a new project. One of the benefits of Nx is that it can determine which apps in the monorepo are affected by a range of changes (start commit, end commit). So if you have a bunch of apps, you only have to build, test, and deploy the apps that are actually affected by the changes instead of the entire monorepo. I'd like to setup a GitHub Action workflow to deploy only the affected apps on push or merge to master. However, I'm having trouble figuring out how

API requests returning errors trying to access NestJS backend from Angular frontend

隐身守侯 提交于 2020-04-17 22:57:11
问题 When making an API call to my NestJS app I'm receiving the following errors. core.js:6185 ERROR HttpErrorResponse {headers: HttpHeaders, status: 0, statusText: "Unknown Error", url: " https://localhost:3333/api/product-index ", ok: false, …} and GET https://localhost:3333/api/product-index net::ERR_SSL_PROTOCOL_ERROR From looking into Nest, Angular and NGXS individually and the suggested ways to go about things I have everything set up properly. The only thing I could think to do was tinker