Skip to content

Adds spanish translation for 6-async/01-callbacks #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jun 3, 2020

Conversation

lizzie136
Copy link
Member

Contributes issue #9

  • Translates article.md
  • Translates task.md
  • We consider to use 'callback' instead of a translation because
    it is the term used by the community.

  - Translates article.md
  - Translates task.md
  - We consider to use 'callback' instead of a translation because
    it is the term used by the community.
@lizzie136 lizzie136 added this to the 6-async milestone Apr 2, 2019

Now let's say we need not just a circle, but to show a message inside it. The message should appear *after* the animation is complete (the circle is fully grown), otherwise it would look ugly.
El la solución de esta tarea, la función `showCircle(cx, cy, radius)` dibuja el círulo, pero no hay manera de rastrea cuando está listo.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pero no hay manera de rastrear

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pero no hay manera de saber


The call initiates the script loading, then the execution continues. While the script is loading, the code below may finish executing, and if the loading takes time, other scripts may run meanwhile too.
La llamada inicia la carga del script, luego la ejecución continua. Mientras el script está cargando, el código de abajo podría terminar su ejecución, y si la carga toma tiempo, otros scripts también pueden correr mientras tanto.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

el código de abajo podría

el código que continua podría


```js
loadScript('/my/script.js', function() {
// the callback runs after the script is loaded
newFunction(); // so now it works
// el callbck corre después que el script ha sido cargado
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Runs se traduce en algunas partes como ejecuta y aquí como corre, creo que la mejor traducción y para mantener homogéneo el documento podría ser ejecuta.

});
*/!*
```

That's called a "callback-based" style of asynchronous programming. A function that does something asynchronously should provide a `callback` argument where we put the function to run after it's complete.
Eso se llama un estilo "callback-based" o "basado en callbacks" de programación asíncrona. Una función que hace algo de manera asíncrona debe provee un argumento `callback` donde pongamos la función que correrá luego que sea completada.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

asíncrona debe provee un argumento

asíncrona debe proveer un argumento


From the first look, it's a viable way of asynchronous coding. And indeed it is. For one or maybe two nested calls it looks fine.
## Pirámide de la catástrofe
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

creo que debería de agregarse entre paréntesis el termino en ingles ya que es muy usado por la comunidad y serviría de referencia en ingles.

(Pyramid of Doom)


That's sometimes called "callback hell" or "pyramid of doom."
Esto es a lo que algunas veces llamamos "infierno de callback" o "pirámide de la catástrofe."
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Se podría agregar los términos en ingles para mejore referencia.

"callback hell"
"pyramid of doom.


So this way of coding isn't very good.
Así que esta manera de codear no es tan buena.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

manera de codear

manera de programar


We can try to alleviate the problem by making every action a standalone function, like this:
Podemos intentar aliviar el problema haciendo cada acción una función We can try to alleviate the problem by making every action a independiente, así:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Una parte sigue en ingles.


Also, the functions named `step*` are all of single use, they are created only to avoid the "pyramid of doom." No one is going to reuse them outside of the action chain. So there's a bit of a namespace cluttering here.
Además, las funcies llamadas `step*` son todas de un solo uso. Sólo son creadas para evitar la "pirámide de la catástrofe". Nadie va a reusarlas fuera de la cadena de acciones. Así que hay un poco de sobrecarga de nombres aquí.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Además, las funcies llamadas

Además, las funciones llamadas

@joaquinelio joaquinelio merged commit 4249902 into master Jun 3, 2020
EzequielCaste pushed a commit that referenced this pull request Aug 31, 2020
@joaquinelio joaquinelio deleted the ep-async-callbacks branch December 21, 2020 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants