It's useful to run a function everytime there's a line break -- Enter as well as, for example, ControlC.
With this PR, a new option is added to assign a callback that gets
called every time `renderer.BreakLine()` is called.
Added a test that makes sure the renderer doesn't break if the callback is
not specified, as well as to check that it runs ok when the callback executes.
Just to give a bit more of context: in [ABS](https://github.com/abs-lang/abs)
we are trying to implement ControlR (reverse search), and need to clear
the search selection every time the user "clears" the console, either by
pressing enter or by clearing the current line (eg. ControlC).
* Make possible to change the prefix dynamically
* Add an example for using live-prefix
* Apply live-prefix if it's enabled
* Fix: rendering issue happened when the prefix is empty string Close#27
* Fix the title of propmt
* Remove an excessive blank line
* Refactor: Call `*Render.getCurrentPrefix()` in renderPrefix()