diff options
| author | Ryan Johnson <rjohnson@mozilla.com> | 2021-04-29 16:16:42 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-04-29 16:16:42 -0700 |
| commit | 95aca4b4d8fa62815d4bd412fff1a364f842814a (patch) | |
| tree | 5e57661720fe9058d5c7db637e764800b50f9060 /files/uk/web/javascript/reference/global_objects/date/tojson | |
| parent | ee3b1c87e3c8e72ca130943eed260ad642246581 (diff) | |
| download | translated-content-95aca4b4d8fa62815d4bd412fff1a364f842814a.tar.gz translated-content-95aca4b4d8fa62815d4bd412fff1a364f842814a.tar.bz2 translated-content-95aca4b4d8fa62815d4bd412fff1a364f842814a.zip | |
remove retired locales (#699)
Diffstat (limited to 'files/uk/web/javascript/reference/global_objects/date/tojson')
| -rw-r--r-- | files/uk/web/javascript/reference/global_objects/date/tojson/index.html | 69 |
1 files changed, 0 insertions, 69 deletions
diff --git a/files/uk/web/javascript/reference/global_objects/date/tojson/index.html b/files/uk/web/javascript/reference/global_objects/date/tojson/index.html deleted file mode 100644 index 6e03a8664e..0000000000 --- a/files/uk/web/javascript/reference/global_objects/date/tojson/index.html +++ /dev/null @@ -1,69 +0,0 @@ ---- -title: Date.prototype.toJSON() -slug: Web/JavaScript/Reference/Global_Objects/Date/toJSON -tags: - - Date - - JavaScript - - Method - - Prototype - - Дата - - Довідка -translation_of: Web/JavaScript/Reference/Global_Objects/Date/toJSON ---- -<div>{{JSRef}}</div> - -<p>Метод <strong><code>toJSON()</code></strong> подає об'єкт {{jsxref("Date")}} у вигляді рядка.</p> - -<p>{{EmbedInteractiveExample("pages/js/date-tojson.html")}}</p> - -<div class="hidden"> -<p>The source for this interactive example is stored in a GitHub repository. If you'd like to contribute to the interactive examples project, please clone <a href="https://github.com/mdn/interactive-examples">https://github.com/mdn/interactive-examples</a> and send us a pull request.</p> -</div> - -<h2 id="Синтаксис">Синтаксис</h2> - -<pre class="syntaxbox notranslate"><code><var>dateObj</var>.toJSON()</code></pre> - -<h3 id="Вертає">Вертає</h3> - -<p>Рядок, що містить текстовий запис зазначеної дати.</p> - -<h2 id="Опис">Опис</h2> - -<p>Кожний об'єкт {{jsxref("Date")}} позначає певну мить у часі. Виклик <code>toJSON()</code> вертає рядок (за допомогою {{jsxref("Date.prototype.toISOString()", "toISOString()")}}), що являє собою текстовий запис дати, яку позначає об'єкт {{jsxref("Date")}}. Зазвичай цей метод вживається для перетворення об'єктів на текст упродовж серіалізації у {{Glossary("JSON")}}.</p> - -<h2 id="Приклади">Приклади</h2> - -<h3 id="Використання_toJSON">Використання <code>toJSON()</code></h3> - -<pre class="brush: js notranslate">var jsonDate = (new Date()).toJSON(); -var backToDate = new Date(jsonDate); - -console.log(jsonDate); //2015-10-26T07:46:36.611Z</pre> - -<h2 id="Специфікації">Специфікації</h2> - -<table class="standard-table"> - <tbody> - <tr> - <th scope="col">Специфікація</th> - </tr> - <tr> - <td>{{SpecName('ESDraft', '#sec-date.prototype.tojson', 'Date.prototype.toJSON')}}</td> - </tr> - </tbody> -</table> - -<h2 id="Підтримка_веб-переглядачами">Підтримка веб-переглядачами</h2> - -<div class="hidden">Таблиця сумісності на цій сторінці створена зі структурованих даних. Якщо ви хочете долучитися до розробки цих даних, пропонуйте нам свої pull request до репозиторію <a href="https://github.com/mdn/browser-compat-data">https://github.com/mdn/browser-compat-data</a>.</div> - -<p>{{Compat("javascript.builtins.Date.toJSON")}}</p> - -<h2 id="Див._також">Див. також</h2> - -<ul> - <li>{{jsxref("Date.prototype.toLocaleDateString()")}}</li> - <li>{{jsxref("Date.prototype.toTimeString()")}}</li> - <li>{{jsxref("Date.prototype.toUTCString()")}}</li> -</ul> |
