seperated javascript into note.js