Hello all. This is my first post/question so I hope I follow guidelines. I also want to note I have really enjoyed working with Trellis/Bedrock/Sage - the development experience is brilliant.
I have a Sage-based theme (let’s call it
Theme) that I am developing alongside some plugins (
I wanted to give all of my software the same root namespace (let’s say
BriggySmalls), which leads me to my question: is it not intended for the original
App namespace Sage ships with to be changed?
I have been developing with a different namespace for a while now (
BriggySmalls\Theme) with no issues - despite finding little discussion of it as an approach.
However release Sage 9.0.2 has introduced soberwp/controller release 2.x.x with its PSR4 autoloading which seems to depend on sharing the
App namespace with Sage.
Following the controller guidance I have attempted to use the
sober/controller/namespace filter to change the namespace to
BriggySmalls\Theme\Controllers, however I continue to get the
Class 'App' not found error in the
page-header.blade.php template. Running my debugger it appears that the exception is raised before my filter is executed.
FYI: If I fully namespace
BriggySmalls\Theme\Controllers\App then the exception is not raised.
Is there guidance for anyone wishing to change the default
App namespace? Or is it discouraged? I am willing to abandon my approach if it is not supported.
Thanks in advance for any attention this question gets!