SyntaxFix
Write A Post
Hire A Developer
Questions
i think you have only defined the function. you are not triggering it anywhere.
please do
window.onload = addList();
or trigger it on some other event
after its definition
see this fiddle