stringish function for saving as js