-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
use @roots/bud #2504
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use @roots/bud #2504
Conversation
|
Let's get something implemented in Acorn to handle the manifest stuff a bit more elegantly. cc: @QWp6t |
v2.0.0 next.8
Also adds some about 4 lines of helpful hot reload boilerplate.
|
@retlehs found the cause of the It was a single import: Removed in |
.env.example
Outdated
| APP_NAME='Sage' | ||
| APP_ENV='development' | ||
| APP_SSL=false | ||
| APP_HOST='example.test' | ||
| APP_PUBLIC_PATH='app/themes/sage/dist' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am a bit hesitant with the naming of this file since it could give the impression that secrets go in here which could be devastating for since the theme is public.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it would be sufficient to simply add a warning at the top?
We could be obnoxiously loud about it:
# ⚠ ⚠ ⚠ DO NOT STORE SECRETS HERE!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ya, I thought about that too. It could work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a little more complex and a lot more flexible since v2 launch.
Current behavior:
- Bud only includes env values prefixed by
APP_in bundled code - Bud will explicitly ignore env values including
SECRETin their property name
Examples:
APP_NAME-- included in bundleAPP_SECRET_KEY-- not included in bundleSOME_UNRELATED_KEY-- not included in bundle
Adds imagemin support and bumps to v2.0.6.
|
I included some barebones but functional asset management: https://github.com/roots/sage/blob/2820ae421b225df095da5395d93e24b8a749a45f/app/assets.php. I hope it can be helpful when working out how to enqueue everything in Acorn. I also added a docker-compose file to make it easier to spin up sage. |
|
New:
{entrypoints: { app: ["app.js"] } }
|
sage.config.js
Outdated
| /** | ||
| * Sage theme | ||
| */ | ||
| const theme = Sage.bootstrap(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@roots/sage exports a bootstrap config and a tailwind config. They're wrapped so they don't conflict with another.
@Log1x to check out the one I did based on your PR, call Sage.tailwind() instead. I believe the rest of the file is the same between the two configs. But, it still expects js to be scripts and css to be styles.
Config preset source for both in this dir: https://github.com/roots/bud/tree/stable/packages/sage/src/sage
|
Updated to 3.0.28, which adds the
|
|
Closing in favor of #2643, which is way fresher. |

This PR replaces laravel-mix with @roots/bud.