In order to prevent bloating of the theme folder, I put all frontend stuff in a subdirectory called static where there resides my wpack project, however, the paths are broken in my WordPress website. The result is like something below, it prints undefined at the beginning of paths.
undefinedreactapp/assets/logo-5a37ec92.png
However, If I put the wpack project in the base directory of the theme everything works properly.
I also can't set outputPath in wpackio.project.js to 'static/public' since it has to be a single directory name as per wpack documentation.
I imagine this problem could be from my php code
$this->enqueue = new \WPackio\Enqueue( 'test', 'static/public', '1.0.0', 'theme', false );
I set the output to static/public in WPackio Enqueue instantiation however WordPress still can't produce the correct path. As per documentation, it should be the same as outputPath in wpackio.project.js file but it doesn't make sense in this case.
In order to prevent bloating of the theme folder, I put all frontend stuff in a subdirectory called static where there resides my wpack project, however, the paths are broken in my WordPress website. The result is like something below, it prints undefined at the beginning of paths.
undefinedreactapp/assets/logo-5a37ec92.png
However, If I put the wpack project in the base directory of the theme everything works properly.
wpackio.project.js
I also can't set outputPath in wpackio.project.js to 'static/public' since it has to be a single directory name as per wpack documentation.
I imagine this problem could be from my php code
$this->enqueue = new \WPackio\Enqueue( 'test', 'static/public', '1.0.0', 'theme', false );
I set the output to static/public in WPackio Enqueue instantiation however WordPress still can't produce the correct path. As per documentation, it should be the same as outputPath in wpackio.project.js file but it doesn't make sense in this case.
Any help would be appreciated.