diff --git a/.gitignore b/.gitignore index a85e3847d..a4724859d 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ jspm_packages !/log/.keep /tmp +package-lock.json \ No newline at end of file diff --git a/index.js b/index.js index e36025b00..41344406b 100644 --- a/index.js +++ b/index.js @@ -1,2 +1,9 @@ function addingEventListener() { + const input = document.getElementById('button'); + + function clickAlert() { + alert('I was clicked!'); + } + + input.addEventListener('click', clickAlert); }