When installing acorn via composer inside bedrock and calling the following setup function in the functions file of my theme, I get error telling me that it’s trying to define the constants that are set in application.php a second time (and crashes).
I have tried installing a sage theme and following it via xdebug, but - in sage - it does not consider bedrock’s /config folder as config filees and so doesn’t cause the issue.
Is there a way to tell acorn that config files are already loaded when calling it without sage?
I’d have to recreate non-private project to provide a repo so that will have to wait.
Basically, what I’ve seen is that acorn being called inside a theme returns {project_root}/config as $app->configPath and sage returns {theme_root}/config as $app->configPath
One final note for people who might fall unto this issue in the future.
As written here : Directory Structure | Acorn Docs | Roots
With bedrock, you’re only supposed to install Acorn inside your theme.
As in, composer inside your theme folder.
I have so many years of pure laravel that when I fell into wordpress + bedrock and considered acorn, I instantly considered that it would go into the bedrock composer.
Either set up your acorn in your theme composer file or set the base path as defined above with configue().