[6.x] Move nocache views to Statamic temporary storage - #15363
[6.x] Move nocache views to Statamic temporary storage#15363jackmcdade wants to merge 2 commits into
Conversation
|
Review:
tbh I think we should just tell people to ignore We put our nocache views within storage/framework/views because it'll be a safe spot depending on the server config. If your server requirements need you to move the compiled views somewhere else, you customize I think a better solution might be:
That'd fix new sites, and for existing sites they could just add the new ignore rule to their existing vite config. |
|
OK, should we open a new PR for that and then close this one? |
|
This PR could probably still just do the |
9363cd8 to
2a7af98
Compare
|
Updated this PR to store all three nocache-generated view types in |
What this changes
Statamic generates temporary views for Antlers nocache regions, Blade nocache components, and
@antlersblocks. These files were stored alongside Laravel’s compiled views, with two paths writing directly tostorage/framework/views.All three types of generated view now live in
storage/statamic/tmp/nocache. This keeps Statamic’s temporary files together in the application’s normal writable storage directory and gives Vite one consistent location to ignore.The companion change in statamic/statamic#152 updates the default Vite configuration so these generated files do not trigger browser refreshes during
npm run dev.Related to #13158.
Testing