Hello! Is it possible to run applications on node + angular without express? All examples of bundles of node and angular using express only. I would be grateful if you tell in which direction to look.

  • In my opinion, this is an XY problem. What dictates the desire to get rid of express? - D-side
  • On hosting node.js works through passenger. Express refuses to work. Here is a related question I created earlier: ru.stackoverflow.com/questions/520833/… - Megazilla
  • The node is installed correctly, for routing I tried to use rooter-router from npm. Everything is working. - Megazilla
  • Straight sockets can not do? HTTP also works over TCP's sockets ... so if this is the case, then there is no way to publish any web application at all. Check the limitations of your hoster. How they offer to handle HTTP requests without sockets. - D-side
  • It looks like yes, it’s not a matter of sockets) I also searched the Internet and understood that I didn’t put the question in the wrong way. from ignorance. And it seems that you need to write a router instead of express, which can work with static files - Megazilla

1 answer 1

In fact, express is just a small add-on to the connect framework https://github.com/senchalabs/connect which in turn simplifies working with the built-in http nodejs module.

To understand, you can see the course from Ilya Kantor on nodejs https://www.youtube.com/watch?v=ILpS4Fq3lmw&list=PLDyvV36pndZFWfEQpNixIHVvp191Hb3Gg

  • In general, by typing it was possible to determine that the application crashes due to console.log. I removed the express (it still was redundant for me), replaced it with my own implementation + rooten-router from npm. And it all worked. :) Very strange thing. Thanks for the referral, I would have known it before, I saved a lot of time - Megazilla