Hello,
I just installed a fresh version of Sage;
composer create-project roots/sage theme-name dev-main
I changed the proxy origin and public path to reflect my theme name, nothing unusual.
Whenever I visit 0.0.0.0:3000, the page won’t refresh anymore when I add some HTML. Also there is no styling whatsoever. When I visit my proxy origin, the styling (Tailwind) is visible after refreshing the page.
Am I missing something? My previous project used bud 5.8.7, everything worked as I expected. Now when I use the newest version I run into this problem.
Here are my configs;
bud.config.mjs
// @ts-check
/**
* Build configuration
*
* @see {@link https://bud.js.org/guides/getting-started/configure}
* @param {import('@roots/bud').Bud} app
*/
export default async (app) => {
app
/**
* Application entrypoints
*/
.entry({
app: ["@scripts/app", "@styles/app"],
editor: ["@scripts/editor", "@styles/editor"],
})
/**
* Directory contents to be included in the compilation
*/
.assets(["images"])
/**
* Matched files trigger a page reload when modified
*/
.watch(["resources/views/**/*", "app/**/*"])
/**
* Proxy origin (`WP_HOME`)
*/
.proxy("http://name-domain.nl.test")
/**
* Development origin
*/
.serve("http://0.0.0.0:3000")
/**
* URI of the `public` directory
*/
.setPublicPath("/app/themes/name-theme/public/");
};
package.json
{
"name": "sage",
"private": true,
"browserslist": [
"extends @roots/browserslist-config/current"
],
"engines": {
"node": ">=16.0.0"
},
"scripts": {
"dev": "bud dev",
"build": "bud build",
"translate": "yarn translate:pot && yarn translate:update",
"translate:pot": "wp i18n make-pot . ./resources/lang/sage.pot --include=\"app,resources\"",
"translate:update": "for filename in ./resources/lang/*.po; do msgmerge -U $filename ./resources/lang/sage.pot; done; rm -f ./resources/lang/*.po~",
"translate:compile": "yarn translate:mo && yarn translate:js",
"translate:js": "wp i18n make-json ./resources/lang --pretty-print",
"translate:mo": "wp i18n make-mo ./resources/lang ./resources/lang"
},
"devDependencies": {
"@roots/bud": "6.3.1",
"@roots/bud-tailwindcss": "6.3.1",
"@roots/sage": "6.3.1"
}
}
mode development hash 107775e98a3e20f88539
@roots/bud 6.3.1 webpack 5.73.0
node 18.5.0