aboutsummaryrefslogtreecommitdiff
path: root/files/ru/web/api/network_information_api
diff options
context:
space:
mode:
authorAlexey Pyltsyn <lex61rus@gmail.com>2021-10-27 02:31:24 +0300
committerGitHub <noreply@github.com>2021-10-27 02:31:24 +0300
commit980fe00a74a9ad013b945755415ace2e5429c3c2 (patch)
treea1c6bb4b302e69bfa53eab13e44500eba55d1696 /files/ru/web/api/network_information_api
parent374a039b97a11ee7306539d16aaab27fed66b398 (diff)
downloadtranslated-content-980fe00a74a9ad013b945755415ace2e5429c3c2.tar.gz
translated-content-980fe00a74a9ad013b945755415ace2e5429c3c2.tar.bz2
translated-content-980fe00a74a9ad013b945755415ace2e5429c3c2.zip
[RU] Remove notranslate (#2874)
Diffstat (limited to 'files/ru/web/api/network_information_api')
-rw-r--r--files/ru/web/api/network_information_api/index.html4
1 files changed, 2 insertions, 2 deletions
diff --git a/files/ru/web/api/network_information_api/index.html b/files/ru/web/api/network_information_api/index.html
index ca66acea26..808ca544f1 100644
--- a/files/ru/web/api/network_information_api/index.html
+++ b/files/ru/web/api/network_information_api/index.html
@@ -15,7 +15,7 @@ translation_of: Web/API/Network_Information_API
<p>Данный пример отслеживает изменение подключения пользователя.</p>
-<pre class="brush: js notranslate">var connection = navigator.connection || navigator.mozConnection || navigator.webkitConnection;
+<pre class="brush: js">var connection = navigator.connection || navigator.mozConnection || navigator.webkitConnection;
var type = connection.effectiveType;
function updateConnectionStatus() {
@@ -30,7 +30,7 @@ connection.addEventListener('change', updateConnectionStatus);
<p>The connection object is useful for deciding whether to preload resources that take large amounts of bandwidth or memory. This example would be called soon after page load to check for a connection type where preloading a video may not be desirable. If a cellular connection is found, then the <code>preloadVideo</code> flag is set to false. For simplicity and clarity, this example only tests for one connection type. A real-world use case would likely use a switch statement or some other method to check all of the possible values of {{domxref("NetworkInformation.type")}}. Regardless of the <code>type</code> value you can get an estimate of connection speed through the {{domxref("NetworkInformation.effectiveType")}} property.</p>
-<pre class="brush: js notranslate">let preloadVideo = true;
+<pre class="brush: js">let preloadVideo = true;
var connection = navigator.connection || navigator.mozConnection || navigator.webkitConnection;
if (connection) {
if (connection.effectiveType === 'slow-2g') {