added list manipulation with javascript