BlazorLiveReload icon indicating copy to clipboard operation
BlazorLiveReload copied to clipboard

Preview does not support interactivity

Open dharmaturtle opened this issue 6 years ago • 1 comments

This is a very interesting idea, but unfortunately, the /preview page isn't interactive. If I understand the code correctly, it renders the most recently changed *.razor to a file called preview.html. However, due to preview.html being a static file, you can't interact with it, i.e. push the Counter button to increment the count.

This is still great for previewing HTML tweaks so you don't have to wait for everything to recompile. Sometimes you don't want to test interactivity - you just wanna see what it looks like!

If my other PR goes through, I'll make a new one to add these details to your Readme :)

dharmaturtle avatar Feb 23 '20 23:02 dharmaturtle

Yes, you are correct, it renders the most recently changed *.razor files.

There is an idea to intercept every request and add WebSockets code to every page. That means it should work for every route.

martasp avatar Feb 23 '20 23:02 martasp