How to write this .htaccess?

I have this folder structure is obtained :

/dist
/dist/index.html
/api


in the dist folder is index.html and the js files, css, etc.
in the folder API, respectively the server part.
How to write .htaccess so that when you try to file the link is changed to dist/file_name, and if the request goes to the api did not change anything?
March 23rd 20 at 19:21
1 answer
March 23rd 20 at 19:23
Good day! As the saying goes: Give a man a fish you feed him for a day, teach a man to fish he'll eat for a lifetime! Read these articles:
1) https://habr.com/ru/post/264395/
2) https://habr.com/ru/company/sprinthost/blog/129560/
3) https://habr.com/ru/post/141424/
4) https://htmlweb.ru/php/htaccess-mod_rewrite-rewrit...

Written htaccess can test here

Find more questions by tags htaccess