Closed woutdp closed 1 year ago
Maybe possible with:
notify: [ live_svelte: [~r"priv/static/assets/server/.*(js|css)$"], ]
which will send an event
{:phoenix_live_reload, :live_svelte, "the/path/of/the/file/that/changed"},
And then catching the message in the supervisor and restarting the workers
Testing it out by running:
alias Phoenix.PubSub PubSub.subscribe(PhoenixBlank.PubSub, "live_svelte") # Trigger the event by changing a file Process.info(self(), :messages)
Instead of resetting the supervisor, we simply delete the cache in the SSR server render function
Maybe possible with:
which will send an event
And then catching the message in the supervisor and restarting the workers
Testing it out by running: