aboutsummaryrefslogtreecommitdiff
path: root/files/ko/web/javascript/reference/global_objects/intl/locale/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'files/ko/web/javascript/reference/global_objects/intl/locale/index.html')
-rw-r--r--files/ko/web/javascript/reference/global_objects/intl/locale/index.html77
1 files changed, 77 insertions, 0 deletions
diff --git a/files/ko/web/javascript/reference/global_objects/intl/locale/index.html b/files/ko/web/javascript/reference/global_objects/intl/locale/index.html
new file mode 100644
index 0000000000..a768a8bb5d
--- /dev/null
+++ b/files/ko/web/javascript/reference/global_objects/intl/locale/index.html
@@ -0,0 +1,77 @@
+---
+title: Intl.Locale
+slug: Web/JavaScript/Reference/Global_Objects/Intl/Locale
+tags:
+ - Internationalization
+ - Intl
+ - JavaScript
+ - NeedsTranslation
+ - Reference
+ - TopicStub
+translation_of: Web/JavaScript/Reference/Global_Objects/Intl/Locale
+---
+<div>{{JSRef}}</div>
+
+<p><span class="seoSummary">The <strong><code>Intl.Locale</code></strong> constructor is a standard built-in property of the Intl object that represents a Unicode locale identifier.</span></p>
+
+<p>{{EmbedInteractiveExample("pages/js/intl-locale.html")}}</p>
+
+<h2 id="Syntax">Syntax</h2>
+
+<pre class="syntaxbox">new Intl.Locale(<var>tag</var> [, <var>options</var>])</pre>
+
+<h3 id="Parameters">Parameters</h3>
+
+<dl>
+ <dt><code>tag</code></dt>
+ <dd>The Unicode locale identifier string.</dd>
+ <dt><code>options</code></dt>
+ <dd>An object that contains configuration for the Locale. Keys are Unicode locale tags, values are valid Unicode tag values.</dd>
+</dl>
+
+<h2 id="Description">Description</h2>
+
+<p>The <code><strong>Intl.Locale</strong></code> object was created to allow for easier manipulation of Unicode locales. Unicode represents locales with a string, called a <em>locale identifier</em>. The locale identifier consists of a <em>language identifier</em> and <em>extension tags</em>. Language identifiers are the core of the locale, consisting of <em>language</em>, <em>script</em>, and <em>region subtags</em>. Additional information about the locale is stored in the optional <em>extension tags</em>. Extension tags hold information about locale aspects such as calendar type, clock type, and numbering system type.</p>
+
+<p>Traditionally, the Intl API used strings to represent locales, just as Unicode does. This is a simple and lightweight solution that works well. Adding a Locale class, however, adds ease of parsing and manipulating the language, script, and region, as well as extension tags.</p>
+
+<p><span style="">The Intl.Locale object has the following properties and methods:</span></p>
+
+<h3 id="Properties">Properties</h3>
+
+<dl>
+ <dt>{{jsxref("Locale.prototype", "Intl.Locale.prototype")}}</dt>
+ <dd>The prototype object for the <code>Locale</code> constructor.</dd>
+</dl>
+
+<h2 id="Specifications">Specifications</h2>
+
+<table class="standard-table">
+ <tbody>
+ <tr>
+ <th scope="col">Specification</th>
+ <th scope="col">Status</th>
+ <th scope="col">Comment</th>
+ </tr>
+ <tr>
+ <td><a href="https://tc39.github.io/proposal-intl-locale/#locale-objects">Intl.Locale proposal</a></td>
+ <td>Stage 3</td>
+ <td></td>
+ </tr>
+ </tbody>
+</table>
+
+<h2 id="Browser_compatibility">Browser compatibility</h2>
+
+<div>
+
+
+<p>{{Compat("javascript.builtins.Intl.Locale")}}</p>
+</div>
+
+<h2 id="See_also">See also</h2>
+
+<ul>
+ <li> <a href="https://github.com/zbraniecki/Intl.js/tree/intllocale">The Intl.Locale Polyfill</a></li>
+ <li><a href="https://www.unicode.org/reports/tr35/#Canonical_Unicode_Locale_Identifiers">Unicode locale identifiers spec</a></li>
+</ul>