From 074785cea106179cb3305637055ab0a009ca74f2 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:42:52 -0500 Subject: initial commit --- .../global_objects/string/touppercase/index.html | 135 +++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 files/pt-br/web/javascript/reference/global_objects/string/touppercase/index.html (limited to 'files/pt-br/web/javascript/reference/global_objects/string/touppercase') diff --git a/files/pt-br/web/javascript/reference/global_objects/string/touppercase/index.html b/files/pt-br/web/javascript/reference/global_objects/string/touppercase/index.html new file mode 100644 index 0000000000..3a593fc9b8 --- /dev/null +++ b/files/pt-br/web/javascript/reference/global_objects/string/touppercase/index.html @@ -0,0 +1,135 @@ +--- +title: String.prototype.toUpperCase() +slug: Web/JavaScript/Reference/Global_Objects/String/toUpperCase +tags: + - Caixa alta + - JavaScript + - Letras maúsculas + - Método(2) + - Protótipo(2) + - Referência(2) + - String + - toUpperCase() +translation_of: Web/JavaScript/Reference/Global_Objects/String/toUpperCase +--- +
{{JSRef}}
+ +

O método toUpperCase() retorna o valor da string original convertido em letras maiúsculas.

+ +

Sintaxe

+ +
str.toUpperCase()
+ +

Valor retornado

+ +

Uma nova string representando a string original convertida em maiúsculas.

+ +

Exceções

+ +
+
{{jsxref("TypeError")}}
+
Quando chamado em uma string contendo valor {{jsxref("null")}} ou {{jsxref("undefined")}}, por exemplo, String.prototype.toUpperCase.call(undefined).
+
+ +

Descrição

+ +

O método toUpperCase() retorna o valor da string convertido para letras maiúsculas. toUpperCase() não altera o valor da string original.

+ +

Exemplos

+ +

Uso básico

+ +
console.log('alfabeto'.toUpperCase()); // 'ALFABETO'
+
+ +

Especificações

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
EspecificaçãoStatusComentário
{{SpecName('ES1')}}{{Spec2('ES1')}}Definição inicial. Implementado no JavaScript 1.0.
{{SpecName('ES5.1', '#sec-15.5.4.18', 'String.prototype.toUpperCase')}}{{Spec2('ES5.1')}}
{{SpecName('ES6', '#sec-string.prototype.touppercase', 'String.prototype.toUpperCase')}}{{Spec2('ES6')}}
{{SpecName('ESDraft', '#sec-string.prototype.touppercase', 'String.prototype.toUpperCase')}}{{Spec2('ESDraft')}}
+ + + +
{{CompatibilityTable}}
+ +
+ + + + + + + + + + + + + + + + + + + +
CaracterísticaChromeFirefox (Gecko)Internet ExplorerOperaSafari
Suporte básico{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}
+
+ +
+ + + + + + + + + + + + + + + + + + + + + +
CaracterísticaAndroidChrome for AndroidFirefox Mobile (Gecko)IE MobileOpera MobileSafari Mobile
Suporte básico{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}{{CompatVersionUnknown}}
+
+ +

Veja também

+ + -- cgit v1.2.3-54-g00ecf