Made editors into a class
Refactoring javascript.