eta icon indicating copy to clipboard operation
eta copied to clipboard

Async Streaming

Open shadowtime2000 opened this issue 5 years ago • 1 comments

Is your feature request related to a problem? Please describe. No not really.

Describe the solution you'd like A function, stream?, that creates a stream which can be sent to the browser or destination for faster TTB.

Describe alternatives you've considered None.

shadowtime2000 avatar Jan 10 '21 19:01 shadowtime2000

This will most likely require #70 so we can shim the streams if they can be used. I see two ways to handle this:

  1. Parse the entire thing and then render bit by bit

We could parse the entire template and then keep on splicing parts of the AST off and rendering them instead of rendering the entire AST.

  1. Parse bit by bit and render bit by bit

We could also use a special parsing engine based off the one we currently have which will find each %> parse until that and then render that and then repeat.

The second one would probably be a lot more faster than the first one, but it would be hard to do the partial parsing especially since we have stuff like allowing delimiters in comments and such. If we did the second way I think it would be best to wait until @nebrelbug shows up to do his parsing magic and stuff.

shadowtime2000 avatar Jan 10 '21 19:01 shadowtime2000