I went through answer from this question Angular 5 Build routes from API data at startup as a guide to load routes from backend, then I noticed that I can't navigate to those routes, that I loaded to routerConfig from API.
I found the reason for that and it turned out that my application is using server site rendering so I have initialNavigation
set as 'enabled' and thats the reason that my routes not being registered.
Docs says: "This value is required for server-side rendering to work."
I need solution to load routes from API while keeping SSR since app needs to be SEO friendly, is there is a good solution to do that ? as I am googling for a while and can't find anything usefull in those circumstances.