To get to a real online compilation other software such as BaKoMa TeX use a modified (La-)TeX. With the newer LuaTeX it is easier to hook deep into the internals, maybe this is a route that you can investigate.
As a workaround what can be done though is to start the compilation with LaTeX up to the point of the current cursor position in your editor. Let's say your complete document looks as follows:
Some more example text.
Instead of continuing, end input here and abort the compilation, the DVI file will still get written up to this point.
It is possible to input and compile the first block with LaTeX. Then when the user takes a short break the compilation can continue and can be aborted for example at the next page. The DVI document is then almost immediately available. In the background you can then start the compilation process up to the point of the cursor again so that it does not interrupt user workflow.
With a modified LaTeX executable the first optimization would be recording the compilation process in a kind of cache, so that the part before the current page does not need to be compiled again ever unless it changes. That makes this approach also somewhat feasible, there is no programmatic way to influence the content of a previous page with code on the later pages. This sets a LaTeX file apart from e.g. a C source file where at the end of the file previous parts can be changed.