pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/javascript-tutorial/es.javascript.info/pull/427.patch

nces llamado "JSONP (JSON con padding)" era utilizado. -Here's how it worked. +Veamos como se utilizaba. -Let's say we, at our site, need to get the data from `http://another.com`, such as the weather: +Digamos que, en nuestro sitio es necesario obtener datos de `http://another.com`, como podría ser el pronóstico del tiempo: -1. First, in advance, we declare a global function to accept the data, e.g. `gotWeather`. +1. Primero, adelantándonos, creamos una función global para aceptar los datos, por ejemplo: `gotWeather`. ```js - // 1. Declare the function to process the weather data + // 1. Se declara la función para procesar los datos del tiempo function gotWeather({ temperature, humidity }) { alert(`temperature: ${temperature}, humidity: ${humidity}`); } ``` -2. Then we make a `