Refact module/view

Signed-off-by: Marcin Pyrka <pyrka.marcin@gmail.com>