adds javascript directory. begins linked list in js with testing for existence of head and node