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


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

URL: http://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/String/toUpperCase

tps://developer.mozilla.org/favicon.ico" />

Dieser Inhalt wurde automatisch aus dem Englischen übersetzt, und kann Fehler enthalten. Erfahre mehr über dieses Experiment.

View in English Always switch to English

String.prototype.toUpperCase()

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since Juli 2015.

Die toUpperCase() Methode von String-Werten gibt diesen String in Großbuchstaben konvertiert zurück.

Probieren Sie es aus

const sentence = "The quick brown fox jumps over the lazy dog.";

console.log(sentence.toUpperCase());
// Expected output: "THE QUICK BROWN FOX JUMPS OVER THE LAZY DOG."

Syntax

js
toUpperCase()

Parameter

Keine.

Rückgabewert

Ein neuer String, der den aufrufenden String in Großbuchstaben konvertiert darstellt.

Beschreibung

Die toUpperCase()-Methode gibt den Wert des Strings in Großbuchstaben konvertiert zurück. Diese Methode beeinflusst nicht den Wert des Strings selbst, da JavaScript-Strings unveränderlich sind.

Beispiele

Grundlegende Nutzung

js
console.log("alphabet".toUpperCase()); // 'ALPHABET'

Umwandlung von Nicht-String-this-Werten zu Strings

Diese Methode konvertiert jeden Nicht-String-Wert in einen String, wenn Sie dessen this auf einen Wert setzen, der kein String ist:

js
const a = String.prototype.toUpperCase.call({
  toString() {
    return "abcdef";
  },
});

const b = String.prototype.toUpperCase.call(true);

// prints out 'ABCDEF TRUE'.
console.log(a, b);

Spezifikationen

Specification
ECMAScript® 2026 Language Specification
# sec-string.prototype.touppercase

Browser-Kompatibilität

Siehe auch

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy