Refactoring backend and adding backbone for the FE