Мое приложение использует Laravel12 в качестве серверной части и Vuejs в качестве внешнего интерфейса.
Внешний интерфейс устанавливается непосредственно на домен.fr, а серверная часть на backend.domain.fr.
Структура папок хостинга следующая:
Код: Выделить всё
htdocs/
|--assets(dir) //for the frontend
|--index.html //for frontend
|--backend(dir)
|--app(dir)
|--bootstrap(dir)
|--config(dir
|--sanctum.php
|--cors.php
|-- (etc.)
|--database(dir)
|--public(dir)
|--resources(dir)
|--routes(dir)
|--api.php
|--auth.php
|--web.php
|--storage(dir)
|--test(dir)
|--vendor(dir)
|--backend.denentzat.fr //the document root of the sub domain
|--index.php
|--.htaccess
Код: Выделить всё
Подробнее здесь: [url]https://stackoverflow.com/questions/79809748/backend-laravel-api-and-frontend-vuejs-works-in-dev-but-not-in-production-on-a-s[/url]
Мобильная версия