Ajout d'un exemple pour les appels http.

This commit is contained in:
Florian THIERRY
2023-02-21 15:25:03 +01:00
parent 4002d4226a
commit cfd4838d17
18 changed files with 243 additions and 13 deletions

View File

@@ -8,10 +8,17 @@ import {Car} from "../core/model/car";
})
export class PromisesExampleComponent {
car?: Car = {
id: '1234567890',
id: 1,
brand: 'Toyota',
model: 'Yaris',
power: 12,
numberOfSeats: 5
};
/*
// Async / Await -> + comparaison avec les then
// new Promise "à la main"
// les then chaînés
// catch (avec 1 ou plusieurs then) -> try/catch avec un await
*/
}