Wie füge ich Javascript-Variablen in die Nachricht ein?
swal({ Titel: „Fehler!“, Text: „Javascript-Variable?“ Typ: „Fehler“, ConfirmButtonText: „Cool“ });
var myVariable = 'Hello World';
swal({
title: "Error!",
text: myVariable,
type: "error",
confirmButtonText: "Cool"
});
@t4t5 @WeirdestYeti @zenflow wie kann ich die Farbe des Textes bearbeiten, nachdem ich ihm eine Variable zugewiesen habe?
@jsandleraol https://sweetalert.js.org/docs/#swal -text
Hilfreichster Kommentar
var myVariable = 'Hello World'; swal({ title: "Error!", text: myVariable, type: "error", confirmButtonText: "Cool" });