Cleaning up the eidtor to make it into a template and integrate it with the model instead of making it a static js file.