Albert Tsang SHSI
Albert Tsang SHSI

Reputation: 35

how to access localhost:4200 (Angular App) on Big Sur from another computer within the same lan?

screencapture : linksys port-forward table

My case is listed as below :

My Question is :

  1. What else should be further set so that the site on the server computer can be reached from the client's computer ?
  2. Should I consider to make some configuration on the linksys port forwarding policy?

Thanks.

Upvotes: 0

Views: 6210

Answers (1)

Albert Tsang SHSI
Albert Tsang SHSI

Reputation: 35

Answers from "NSteinbusch @ https://discord.davidbombal.com/ " :

  • this is an Angular issue rather than networking issue ;
  • by default angular only listen on local interface 127.0.0.1 ;
  • By using the following command on the command prompt ng serve --host 0.0.0.0, instead of simply typing ng serve to start the app, the client PC should be able to reach the Angular app of the server at http://192.168.1.149:4200/
  • By this method, the server will listen to all available interface, so your Ethernet NIC or Wi-Fi NIC as well.

Upvotes: 1

Related Questions