-
Notifications
You must be signed in to change notification settings - Fork 26
I must use asset-map:compile to see modification #77
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
Comments
Could be related: 81c9e6f - make sure (for now) that Tailwind 3 is being downloaded |
I'm facing similar problem, when I add or edit classes in my 'main/homepage.html.twig' template, tailwind:build -w doesn't show any rebuilding changes & the browser doesn't reflect those classes' changes as well. |
I'm facing the same issue, even working with Tailwind v3.4.17. The only way to make the new changes work is running asset-map:compile |
Is everyone experiencing this issue using docker? |
yes, I'm using docker |
I'm facing the exact same issue, also using Tailwind v3.4.17, did one of you found a solution except using asset-map:compile ? |
I'm using the https://github.com/dunglas/symfony-docker boilerplate, and experiencing this issue. |
Ok, pretty sure this issue is docker-specific. I don't use this in docker myself so I'll need some help here. |
For my case, this appears to be an issue with the By adding # compose.override.yaml
# Development environment override
services:
php:
build:
context: .
target: frankenphp_dev
volumes:
- ./:/app
- ./frankenphp/Caddyfile:/etc/caddy/Caddyfile:ro
- ./frankenphp/conf.d/20-app.dev.ini:/usr/local/etc/php/app.conf.d/20-app.dev.ini:ro
# If you develop on Mac or Windows you can remove the vendor/ directory
# from the bind-mount for better performance by enabling the next line:
# - /app/vendor
- ./var:/app/var
environment:
MERCURE_EXTRA_DIRECTIVES: demo
# See https://xdebug.org/docs/all_settings#mode
XDEBUG_MODE: "${XDEBUG_MODE:-off}"
extra_hosts:
# Ensure that host.docker.internal is correctly defined on Linux
- host.docker.internal:host-gateway
tty: true
###> symfony/mercure-bundle ###
###< symfony/mercure-bundle ###
###> doctrine/doctrine-bundle ###
database:
ports:
- "3306"
###< doctrine/doctrine-bundle ### Shoutout to this comment I came across on Symfonycasts. Caveat - The |
I'm not using Docker but I still have the same issue. I need to compile everytime I want to see changes on my web page. |
Hi everyone! We can't replicate, but I can give more info, then I'm hoping someone who is having the issue can debug: It’s confusing because we have to compile commands (tailwind and asset mapper), both in watch mode. Let’s assume (which I think is the case) that tailwind’s watch mode is working. In that case, the problem is asset mapper’s watch not seeing the changes to the built tailwind file, which lives in the var/ directory. I did see someone comment on mapping var/ in docker for this to work. I'd be curious if that fixes the issue for other docker users. For all situations: what happens if you touch or manually modify the built tailwind file in var/? Does asset-mapper:build's watch see that change? Do you see the changes in your browser without needing to restart the asset-mapper:build command? Finally if var/ for some reason is causing trouble, we could try storing the built tailwind file in a /tmp/ OS directory. I can't remember if there is a requirement that the built file live IN the project, but it may be worth a shot |
I had the exact same problem. My solution was to delete the I still get the issue when I run I hope it helps someone. I am also not using docker for development. |
Thanks that was the solution ! Deleting the public/assets folder and only using symfony server:start and php bin/console tailwind:build --watch works afterwards. |
Ok, looks like this is an asset-mapper thing rather than a tailwind-bundle thing. Basically, |
Hi !
I'm using the template from dunglas/symfony-docker. I followed the instruction to build/launch my container and installed the bare minimum according to documentation:
Twig:
symfony/twig-bundle
Asset-mapper:
symfony/asset-mapper
symfony/asset
symfony/twig-pack
Tailwindbundle:
symfonycasts/tailwind-bundle
After installing those according to documentation, i created a simple controller to use my twig file but i encounter an error:
An exception has been thrown during the rendering of a template ("Built Tailwind CSS file does not exist: run "php bin/console tailwind:build" to generate it").
Even after running
php bin/console tailwind:build
, the error persists.The only way to stop this error is to compile using
asset-map:compile
.Afterward, every change i've made and built are not applied even when i use the
--poll
and i must rerunasset-map:compile
to see any modification.As it is very inconvenient to use
asset-map:compile
at every change, i wanted to know if there is anyway to make mytailwind:build --watch
works.Also, it's my first issue on GitHub so if there is any modification to make or precision, please tell me.
The text was updated successfully, but these errors were encountered: