Export works
template javascript refactoring