Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions exercises/07-count-on-click/README.es.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

Si tienes **variables globales**, puedes cambiar su valor durante el tiempo de ejecución usando los handlers de eventos. Por ejemplo, este código incrementa el valor de la variable `counter` cada vez que el usuario hace clic en el botón **Increase**.

```js
window.increaseCounter = function increaseCounter() {
counter++;
}
```

## 📝 Instrucciones:

1. Crea un botón que disminuya con una función handler de evento. La función debería disminuir la variable `counter` y actualizar el número en pantalla.
6 changes: 6 additions & 0 deletions exercises/07-count-on-click/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

If you have global variables, you can change their value during runtime using event handlers. For example, this code is increasing the value of the `counter` variable every time the user clicks on the **Increase** button.

```js
window.increaseCounter = function increaseCounter() {
counter++;
}
```

## 📝 Instructions:

1. Create a decrease button with an event handler function. The function should decrease the `counter` variable and update the number on screen.