M
M
Magnus Keef2020-09-01 12:26:20
React
Magnus Keef, 2020-09-01 12:26:20

React app can direct links work?

Good day!
Imagine the situation: we created an application on react, uploaded it to the host, the test.ru domain,
added routes in the application:

  • test.ru/main
  • test.ru/services
    • test.ru/services/service1
    • test.ru/services/service2
    • test.ru/services/service3

  • test.ru/contact


If you go to test.ru then you can go to other pages.
But if, for example, send a direct link to test.ru/services/service2
or test.ru/contact to a friend,
then nothing will be loaded until he goes to test.ru,

how should this work? What should I do to open direct links to application pages?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
alex4answ, 2020-09-01
@alex4answ

send 1 bundle from any uri, and then react-router will do everything by itself

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question