added JS functions to JS lib