13 приёмов и уловок для работы с chrome devtools

Алан-э-Дейл       31.03.2024 г.

Оглавление

Открыть средства разработчика

В Microsoft Edge средства разработчика можно открыть с помощью мыши или клавиатуры любым из следующих способов. То, какое средство открыто, зависит от того, как вы открываете DevTools.

Основные способы:

Действие Результирующее средство
Щелкните правой кнопкой мыши любой элемент на веб-странице и выберите пункт » Проверить». Инструмент Elements с расширением дерева DOM для отображения элемента страницы, щелкнув правой кнопкой мыши.
Нажмите ++ (Windows/Linux) или ++(macOS). Ранее использованное средство или средство приветствия .
Нажмите клавишу . Ранее использованное средство или средство приветствия .

Дополнительные способы:

Действие Результирующее средство
На панели Microsoft Edge выберите Параметры () > дополнительные > средства Средства разработчика. Ранее использованное средство или средство приветствия .
Нажмите ++ (Windows, Linux) или ++(macOS). Средство консоли .
Нажмите ++ (Windows, Linux) или ++(macOS). Средство Elements с развернутным деревом DOM, чтобы отобразить элемент.
Нажмите + , чтобы открыть контекстное меню. Чтобы выбрать команду «Проверить «, нажмите и нажмите кнопку . . Средство Elements с развернутным деревом DOM, чтобы отобразить элемент.
Нажмите и + переместите фокус на элемент страницы. Затем нажмите, + чтобы открыть контекстное меню. Чтобы выбрать команду «Проверить «, нажмите и нажмите кнопку . . Инструмент Elements с расширением дерева DOM для отображения элемента страницы с фокусом.

Откройте DevTools, щелкнув правой кнопкой мыши элемент на веб-странице

Хороший способ открыть DevTools — щелкнуть правой кнопкой мыши элемент на веб-странице и выбрать пункт «Проверить»:

Откроется devTools с выделенным правой кнопкой мыши элементом в дереве DOM в средстве Elements :

На панели Microsoft Edge можно выбрать Параметры и другие () > дополнительные > средства Средства разработчика:

Автоматическое открытие devTools при открытии новой вкладки

Чтобы средства разработчика автоматически открывались при открытии новой вкладки в браузере:

  1. В командной строке откройте Microsoft Edge, передав флаг следующим образом:

    Windows командной строки:

    Windows PowerShell:

    Оболочка bash в macOS:

    Оболочка bash в Linux:

Отключение сочетания клавиш F12

Чтобы запретить нажатие клавиши DevTools:

  1. В Microsoft Edge перейдите к .

  2. В разделе «Средства разработчика » отключите open the DevTools при нажатии клавиши F12.

Подсказка питания: использование меню команд

DevTools предоставляет множество функций и функций для использования с веб-сайтом. Вы можете получить доступ к различным частям DevTools различными способами, но часто для быстрого использования командного меню.

В меню команд средства называются панелями. Например, инструмент Elements называется панелью «Элементы «. Чтобы переключиться на средство «Элементы «, выберите вкладку «Элементы «.

Чтобы открыть меню команд, выполните одно из следующих действий:

  • Нажмите кнопку «Настройка и управление средствами разработки » (Настройка и управление средствами разработки), а затем выберите команду «Выполнить».

  • Нажмите ++ (Windows, Linux) или ++(macOS).

Меню команд позволяет ввести команды для отображения, скрытия или запуска функций в Средствах разработки. Открыв меню команд, введите изменения в слове , а затем выберите «Drawer: Show Changes» (Показать изменения).

Откроется средство «Изменения», которое удобно использовать при редактировании CSS. В этом случае меню команд предоставляет быструю альтернативу выбору дополнительных инструментов (…) и выбору изменений или редактированию файла в средстве «Источники», а затем щелчку правой кнопкой мыши и выбору локальных изменений.

После ввода cha в меню команд отображаются следующие параметры:

Нажмите , а затем откроется средство «Изменения»:

См. также команды запуска с помощью Microsoft Edge команд DevTools.

Сетевые тайминги

В этой панели представлено большое количество временных метрик, связанных с каждым запросом:

Заблокировано — время, проведенное в очереди ожидания подключения к сети.

Отправка — время, затраченное на отправку запроса на сервер.

Получение — это время, затраченное на получение ответа от сервера или, на чтение его из кеша (если он кэширован).

Ожидание — общее время ожидания клиента до получения первого байта. В сторонних инструментах анализа производительности оно называется TTFB или Time to First Byte.

Также есть тайминг поиск DNS — время, необходимое для обработки имени хоста сервера; соединения — время, затраченное на открытие TCP-соединения.

Узнать, какие файлы подключены, и посмотреть их расположение

Порой разработчикам нужно проверить подключенные к проекту файлы и посмотреть их содержимое. В таких случаях на помощь приходит вкладка Sources:

Слева на панели находятся все загруженные ресурсы. Справа — редактор, в котором можно просмотреть любой из загруженных файлов, в том числе изображения. Здесь же можно редактировать CSS и JavaScript. При этом если вы редактируете скрипты, обязательно сохраняйте изменения с помощью команд Command + S  для Mac или Control + S для Windows и Linux. Сохранять правки CSS не нужно, они сразу вступают в силу. Конечно, после перезагрузки страницы всё откатится до начального состояния.

Меняем цвет фона во вкладке Sources

Протестировать блоки на переполнение

Во вкладке Elements можно редактировать не только стили, но и DOM-дерево: добавлять и удалять элементы или блоки, менять текст, управлять атрибутами и классами. Это очень удобно, особенно если нужно протестировать какую-то гипотезу или проверить ошибки в вёрстке.

Одна из задач, выполняемых разработчикам с помощью Chrome DevTools — тестирование вёрстки на переполнение. То есть проверка, как ведут себя блоки и элементы при добавлении контента или изменении размеров страницы. Например, вы можете проверить, не выходит ли текст за рамки блока или не выпадают ли элементы из общего потока.

Популярный среди разработчиков мем и заодно пример того, как не нужно делать: вёрстка не должна ломаться при добавлении новых элементов, увеличении текста или изменении размеров страницы.

Как проверить элемент на переполнение текстом

Во вкладке Elements найдите в DOM-дереве элемент, кликните по нему два раза и добавьте текст:

Добавлять текст можно и на самой странице. Для этого откройте соседнюю вкладку Console, введите команду и нажмите Enter. После запуска команды вы сможете нажать на элемент и отредактировать его.

Переполнение родительских блоков

Чтобы проверить, не выпадают ли блоки из потока и сохраняется ли сетка, найдите родителя и ему добавьте несколько дополнительных дочерних элементов. Для этого кликните на одном из таких элементов правой кнопкой мыши и нажмите на Duplicate Element.


Пример переполнения: элементы выпадают из родительского блока.

Очистить Firefox — как это правильно сделать

Программы не всегда работают стабильно. И браузеры тоже не являются исключением. Если во время работы в Фаерфокс, у вас появляются сообщения об ошибках или зависания, это уже является сигналом, о том, что он работает не должным образом. Из этой инструкции вы узнаете, как очистить Firefox и вновь вернуть его в прежнее «рабочее состояние».

Функция очистки в браузере Firefox

Все личные данные пользователя, а также настройки, сохраняются в папке профиля. Когда запускается очистка, программа удаляет старый профиль, при этом сохраняются все его самые важные данные. Взамен создается новый профиль пользователя, в который эти данные копируются.

При этом все дополнения и расширения, которые были привязаны к профилю полностью удаляются. Однако, если дополнение хранилось не в папке профиля, оно удалено не будет

Сохраняются следующая информация:

  Тонкая настройка Mozilla Firefox

  • Словарь пользователя;
  • Все закладки;
  • Настройки автозаполнения;
  • История загрузок;
  • Файлы куки;
  • Сохраненные пароли.
  • Будет удалено:
  • Интегрированные поисковики;
  • Темы и расширения;
  • Сертификаты безопасности;
  • Настройки панели инструментов;
  • Конфигурация, используемая при загрузке браузера.

Hola VPN Горячие клавиши Java plugin Отзывы о Mozilla Firefox

Очистка Фаерфокс

Чтобы избавить браузер от лишнего мусора и вновь вернуть в прежнее рабочее состояние, выполните следующие действия:

Запустите Фаерфокс и обратите внимание на верхнюю часть интерфейса. Там вы обнаружите кнопку очистки

Нажмите на нее.
После этого браузер автоматически закроется, для того чтобы выполнить очистку.
Когда процесс чистки будет завершен, появится окно, на котором будет содержаться информация о том, какая информация была импортирована. Нажмите на кнопку «Готово».
Дождитесь, когда Mozilla Firefox перезапустится. На этом этапе очистка заканчивается.

В некоторых случаях браузер становится невозможно запустить в обычном режиме. Если у вас такая ситуация, вам следует воспользоваться безопасным режимом работы.

Старый профиль пользователя будет помещен на рабочий стол. Его можно найти в директории «Старые данные Firefox». Поэтому, в случае необходимости, часть несохраненной информации можно будет легко восстановить.

Очистка кэша

Firefox сохраняет некоторые данные, которые пользователь получает во время своих путешествий по просторам интернета. Это могут быть изображения, скрипты и прочие файлы, временное сохранение которых будет ускорять загрузку страниц.

Чтобы очистить кэш, выполните следующие действия:

  1. Нажмите на кнопку «Меню», расположенную в верхней части интерфейса.
  2. Перейдите в раздел «Приватность и Защита»;
  3. Найдите раздел «Куки и данные сайтов».
  4. В этом разделе необходимо воспользоваться кнопкой «Удалить данные».
  5. Внесенные изменения будут сохранены автоматически. Можно закрыть настройки, на этом очистка кэша завершена.

Также браузер можно настроить так, чтобы он сам в автоматическом режиме удалял кэш. Это будет происходить каждый раз, когда пользователь будет выходить из браузера

Чтобы автоматизировать процесс сделайте следующее:

  1. Откройте «Меню».
  2. Перейдите в раздел «Приватность и защита».
  3. В разделе «История» необходимо выбрать «Удалять историю при закрытии Firefox».
  4. Теперь нажмите на кнопку «Параметры», которая находится рядом.
  5. В открывшемся окне нужно поставить галочку напротив пункта «Кэш» и нажмите «Ок».
  6. На этом настойка завершается.

Кстати, для этой цели также можно использовать дополнения. В магазине дополнений для Фаерфокс есть множество вариантов. Поэтому, если хочется удалять кэш «в один клик», не поленитесь ознакомиться с ними.

Заключение

В этой инструкции мы рассказали о том, как очистить браузер Мозила Фирефох и улучшить тем самым его работу. Иногда причина ошибок и медленной работы может быть не в браузере, а вирусах или неправильных настройках операционной системы. Поэтому, перед тем как почистить профиль убедитесь, что это действительно нужно делать.

Официальный дистрибутив Firefox
Тихая установка без диалоговых окон
Рекомендации по установке необходимых программ
Пакетная установка нескольких программ

Скачать InstallPack_mozilla-firefox.exe

firefox-browsers.ru рекомендует InstallPack, с его помощью вы сможете быстро установить программы на компьютер, подробнее на сайте.

7.10 Upgrading a Recipe¶

As software matures, upstream recipes are upgraded to newer versions. As
a developer, you need to keep your local recipes up-to-date with the
upstream version releases. There are several ways of upgrading recipes.
You can read about them in the “”
section of the Yocto Project Development Tasks Manual. This section
overviews the command.

Before you upgrade a recipe, you can check on its upgrade status. See
the “” section
for more information.

The command upgrades an existing recipe to a more
recent version of the recipe upstream. The command puts the upgraded
recipe file along with any associated files into a “workspace” and, if
necessary, extracts the source tree to a specified location. During the
upgrade, patches associated with the recipe are rebased or added as
needed.

When you use the command, you must supply the root
name of the recipe (i.e. no version, paths, or extensions), and you must
supply the directory to which you want the source extracted. Additional
command options let you control things such as the version number to
which you want to upgrade (i.e. the ), the source
revision to which you want to upgrade (i.e. the
), whether or not to apply patches, and so
forth.

Introduction

Google Chrome is a rich and powerful web browser, pioneering what is possible for applications on the web. Google has worked hard to deliver a very fast, very stable, feature rich browsing experience for end users. Google has also ensured that developers like you have a great experience with Chrome. The Developer Tools, bundled and available in Chrome and Safari, allows web developers and programmers deep access into the internals of the browser and their web application.

The Developer Tools are part of the open source Webkit project. Most of the discussion in this article applies to both Google Chrome
and Safari. However, the screenshots were taken using Google Chrome 6, so there may be slight differences in your browser.

In this article, we will take an overview tour of Developer Tools and point out its most popular, and useful, features. Our target audience are web developers who did not know of, or have not yet investigated, the Developer Tools. However, we are sure that even if you are an experienced web developer, you will pick up a tip or two.

If your instance of Developer Tools does not quite match the screenshots found in this article, we recommend you upgrade to 5 so you may follow along and gain access to all of the features described here.

Настройки инструментов для разработчиков

В инструментах для разработчиков есть много параметров, которые помогают настраивать работу с системой. Например, параметры «Включить отметки времени» в веб-консоли или «Отключить HTTP-кеш», который используется для имитации производительности первой загрузки на всех страницах.

Доступ к панели настроек инструментов для разработчиков можно получить различными способами:

Сначала откройте инструменты для разработчиков, а затем:

  • нажмите кнопку «Настройки», представленную в панели инструментов;
  • нажмите клавишу F1, чтобы отобразить панель настроек поверх текущего инструмента;

Здесь можно выбрать инструменты по умолчанию, кнопки, которые необходимо отображать на панели инструментов, темы (темная, светлая, Firebug), а также другие дополнительные настройки.

Wrap Up

Chrome DevTools is a powerful addition to the developer’s bag of tricks. In this article, we examined different productivity and debugging techniques, and best practices which will allow you to better understand how your web apps and components work. We’ve covered how to troubleshoot, inspect and debug them, and how to modify their look and appearance on the fly directly in the browser.

However, that’s only a small part of our dev arsenal. What other tools and tricks do you use? It would be great to hear you share your secrets from your own repertoire in the comments section below.

For more, keep reading our next blog post in this series for additional tips and tricks from our internal development practices.

Do You Want React Certification?

If all this talk about the awesomeness of React developer tools has inspired you to learn React, then Simplilearn has exactly what you’re looking for. The React.js training course teaches and certifies you in React’s basic operations.

The course’s main objective is to help you become familiar with React’s processes and gain the skills needed to become a professional React developer. You will learn React fundamentals via self-paced and instructor-led training, thereby gaining the understanding and know-how for building React components and structure applications with Redux.

According to, React developers can earn an average salary of USD 108,175, with an upper range of USD 163,000. Payscale points out that React developers in India can make an annual average of ₹717,764.

React has been named one of the top ten in-demand web development frameworks for 2021. So if you’re looking for a career that offers not only great rewards but also job security, consider becoming a React developer. And check out Simplilearn’s online courses and bootcamps to help you make your React dreams a reality!

Панель элементов

Панель элементов является наиболее часто используемым инструментом. Он позволяет манипулировать DOM, изменяя веб-страницу.

Чтобы посмотреть, как выглядит веб-страница с различными стилями или и элементами, внесите эти изменения непосредственно в данной панели элементов. Это позволяет редактировать сайт непосредственно в браузере без изменения исходного кода.

Здесь отображается HTML-код веб-страницы. В Chrome это выглядит следующим образом:

В Firefox:

Styles

Здесь отображается весь CSS, заданный для HTML-элементов. В Chrome это выглядит следующим образом:

В Firefox:

Можно редактировать стили выбранного элемента, написав новый код в любом из селекторов CSS.

Я добавил новый размер шрифта для выбранного абзаца.

Подсветка и выбор элемента

Чтобы выбрать определенный элемент, нажмите на значок селектора элемента или воспользоваться клавиатурной комбинацией Ctrl + Shift + C.

В Chrome это выглядит следующим образом:

В Firefox:

Когда селектор активен, элементы, на которые вы наводите курсор, будут подсвечиваться. Если кликнуть по элементу, он будет выбран в панели инспекторе.

Изменение классов и атрибутов

В Chrome после клика правой кнопкой мыши по элементу отобразится опция Edit as HTML или Add attribute.

Если выберите Add attribute, то сможете ввести необходимый атрибут.

Если выбрать Edit attribute, элемент будет преобразован в текстовую область для его редактирования.

Для примера я добавил новые классы в атрибут class и добавил еще один атрибут.

В Firefox это работает аналогично.

Редактирование содержимого HTML-элементов

Для этого достаточно дважды кликнуть по тексту в элементе. После чего откроется поле ввода с содержимым элемента.

Затем нужно задать новые значения и нажать Enter.

Удаление и скрытие элементов DOM

В Chrome кликните правой кнопкой мыши по элементу, который хотите скрыть или удалить. После этого отобразятся соответствующие опции.

После чего элемент будет удален из DOM, и веб-страница будет отображаться без него.

В Firefox схожая опция называется «Удалить узел». И в ней нет возможности скрыть элемент.

Просмотр блочной модели элемента

Инструменты разработчика браузеров позволяют увидеть ширину, высоту, границу, отступы и поля элемента. В Chrome это выглядит следующим образом:

Когда вы наводите курсор на часть блочной модели, этот элемент будет выделен на веб-странице. В Firefox данная функция находится в той же части, что и в Chrome:

Поиск стилей с использованием фильтра

Чтобы найти определенный стиль в коде, введите его название в поле Filter. В Firefox оно находится в той же области, что и в Chrome.

Фильтр выполняет поиск только в иерархии выбранного элемента.

Панель Console

Необходима для логирования диагностической информации в процессе разработки или взаимодействие с JavaScript на странице. Также все ошибки в JavaScript коде, будут выводится здесь с указанием файла и конкретного места в нем где произошла ошибка. Так же в консоль можно выводить XHR запросы. Есть возможность сохранять логи в отдельный файл.
Консоль содержит ряд инструментов и настроек для фильтрации выводимых сообщений, очистки консоли и запрета очистки логов при перезагрузке страницы — Preserve log.

Также консоль может отобразить/скрыть в виде отдельной вкладки находясь на любой другой вкладке и не покидая ее нажав клавишу Esc.

Ключевые возможности:

  • Использование консоли как отдельной панели или как окна рядом с любой другой панелью.
  • Возможность группировать большое колличество сообщения или выведите их на отдельных строках.
  • Очистка всех логов или сохранения их между перезагрузкой страниц, сохранение логов в отдельный файл.
  • Фильтрация по типу сообщения или по регулярному выражению.
  • Логирование XHR запросов.

CPU throttling​

When optimizing the speed of your website you’ll often run into situations where the site is fast on your device but slow for some of your users. For example, pages often load more slowly on phones with slow CPUs than on a desktop device.

DevTools can throttle the CPU and network connection in order to emulate how a user on a slower device would experience your website.

To throttle the CPU, click the gear icon in the Performance tab – not the one at the top right of DevTools! You can then enable a 4-6x slowdown of the CPU.

The screenshot above shows that on a slower device the CPU remains busy even after the initial load. This can make the page less responsive to user interaction, as well as using extra battery power.

For reference, compare the CPU chart above to the one below, where the CPU isn’t throttled.

Using throttling to make page activity easier to understand

In addition to emulating the page experience of your users, throttling also makes it easier to investigate performance problems.

Unless your page is really slow, when loading a page hundreds of events often happen at once, making it hard to understand the relationships and dependencies of different types of page activity. Applying Slow 3G and 6x CPU slowdown throttling will make the page load really slowly, allowing you to look at network requests and CPU tasks one at a time.

7.11 Resetting a Recipe¶

Use the command to remove a recipe and its
configuration (e.g. the corresponding file) from the
workspace layer. Realize that this command deletes the recipe and the
append file. The command does not physically move them for you.
Consequently, you must be sure to physically relocate your updated
recipe and the append file outside of the workspace layer before running
the command.

If the command detects that the recipe or the append
files have been modified, the command preserves the modified files in a
separate “attic” subdirectory under the workspace layer.

Here is an example that resets the workspace directory that contains the
recipe:

Inspect Network Requests

Sometimes you need to check the parameters of the request to the server, or see what the content and the format of the response is. You can do that in the Network panel:

Figure 7

Pro Tips

  • Enable logging of the XHR requests in the console. That will make the XHR requests more easily visible in the console, and left-clicking the result will navigate you directly to that request in the Network panel. Note: Leave «Hide network» unchecked.
  • Check the Disable the cache checkbox. This will prevent the caching of files and requests and can save you some time and troubles when a change made on the server is not applied on the client. Another option to clear the cache is refreshing the page with Ctrl+F5 instead of just F5.

You can imitate a slow connection, which is a very nice way to emulate a mobile connection, by changing the option in the «Online» dropdown in the network tab:

Easy Remote Debugging

18 months ago, Chrome introduced proper remote debugging for WebKit browsers, but if you tried it out back then, you had to deal with a 400MB Android SDK download, adding the binary to your and some magical command line incantations.

Now, we’re happy to announce you can forget all that. Chrome can now natively discover and talk to your USB connected devices. We’ve implemented the protocol directly over USB in Chrome, so you you can easily head to and immediately start your remote debugging session.

This works great in all platforms, including Chrome OS, though do note that on Windows, you’ll need to first install proper USB drivers to talk to the device. If you’ve never tried it before you’ll also need to enable USB debugging on the device and confirm you’re using Chrome for Android Beta. Read the full docs. 😉

Extra bonus: Chrome will now keep your screen from going to sleep while you’re remote debugging. Good for debugging but keep a watch on your device!

Port-forward for local projects

You’re developing on localhost:8000 but your phone can’t reach that. So, we added port forwarding directly into the remote debugging workflow. Now it’s easy to work on your full projects, without any tunneling hacks. On click into Port Forwarding to set what ports you want available, and they’ll light up in green if they’re good to go.

Testing Tools

The most important activity that runs parallel to development is testing, so we have added them to our list of best web development tools. Finally, we will discuss and list down some popular tools that aim to enhance the quality and further accelerate your web application development.

LambdaTest

Nowadays, the definition of an amazing web application or website is quite exhaustive. However, along with the speed and great technology, user experience also plays quite an important role.

In this digital-first era, your website (or web app) must perform exceptionally well on a range of browsers, devices, and operating systems. To realize this perfect experience, you need to perform cross browser testing.

LambdaTest provides you the option to test your website across 2,000+ device-browser-OS combinations, all with different resolutions. Furthermore, the tests are performed in real-time on the cloud. As a result, you can gain a competitive advantage by delivering a unified user experience, faster time-to-market, along with ensuring top-notch product quality. Here are some of the amazing features of the LambdaTest platform:

  • Live Interactive Browser Compatibility Testing
  • Automation Testing using Selenium and Cypress frameworks
  • Parallel Testing in Selenium and Cypress for executing the faster go-to-market strategy
  • Automated Screenshot Testing & Geolocation Testing
  • Detailed test logs (and reports) for faster bug fixes
  • Supports integration with a large number of project management, CI/CD, & communication tools

Selenium IDE

Are you looking for a UI-driven record and playback tool? If yes, then Selenium IDE for automation testing is the right choice for you. Selenium IDE is available for Chrome and Firefox browsers.

Read – Why Selenium IDE is a must for every QA

You can export the created test into a script. It also offers easy debugging by setting breakpoints. The tool also offers multiple strategies for locating a recorded element and has a self-healing feature. also lets you export the recorded tests as code for all official language bindings like Java, C#, Python, etc.

Katalon Studio

Katalon is the perfect tool if you are looking for a middle ground between codeless and code-based testing tools. The tool is an all-in-one solution for test automation that comes with the following features:

  • Productive IDE that can generate tests for all operating systems and platforms
  • Record and store all UI elements, thereby enhancing reusability
  • Offers a codeless experience
  • Seamless integration into the testing ecosystem

Codeless Automation Testing with Katalon & LambdaTest

SoapUI

Built for both testers as well as developers, SoapUI is an open-source tool that offers load, functional, security, as well as mocking testing. With an easy-to-use GUI, this tool is one of the best web development tools if you are a beginner in API testing and want to validate SOAP and REST-based web services.

Here are the major features of the SoapUI framework:

  • Ability to create complex testing scenarios with drag and drop tests
  • Ability to create load tests based on existing API tests
  • Mimic web services without waiting for them to be completed
  • Engaging open-source community

Apache JMeter

Apache JMeter is another popular open-source tool meant for testing the performance of static and dynamic web applications. For example, you can use the tool to simulate a heavy load on a single (or a group of servers), objects, or network.

The objective is to test the application’s strength or analyze how the site performs under different loads. The tool is portable, and you can run headless tests from any Java-compatible operating system like Mac, Windows, or Linux.

States

This section shows all the available entities, their corresponding state and the attribute values. The state and the attribute information is what Home Assistant sees at run time. To update the entity with a new state, or a new attribute value, click on the entity, scroll to the top, and modify the values, and click on “SET STATE” button.

Note that this is the state representation of a device within Home Assistant. That means, it is what Home Assistant sees, and it does not communicate with the actual device in any manner. The updated information can still be used to trigger events, and state changes. To communicate with the actual device, it is recommended to call services in the services section above, instead of updating state.

For example, changing the state from to does not turn on the light. If there is an automation that triggers on the change of the , it will be triggered – even though the actual bulb has not turned on. Also, when the bulb state changes – the state information will be overridden (the refresh icon can be used to retrieve the latest information that Home Assistant has). In other words, the changes that are made through the “States” section are temporary, and is recommended to use for testing purposes only.

The table containing all entities can be filtered for each column. The used search is a wildcard search meaning that if you input “office” in the entity column filter, every entity whose ID matches “*office*” will be shown. You can also add your own wildcards in the search input (e.g., “office*light”).
The attribute filter supports separate filters for attribute names and values, separated by a colon “:”. So the filter “location:3” will result in the table showing all entities that have an attribute name that contains “location” and whose attribute value contains “3”.

Frames and frame rate​

The Frames section of the Performance tab shows a screenshot of every UI update on the page. Each UI update is called a frame, and if the UI is frozen for a long time the frame is called a long frame. The screenshot below shows several long frames, where UI updates are delayed due to heavy JavaScript activity.

Long frames and the frame rate (Frames Per Second, FPS) are also shown right on top of the CPU activity chart.

If you click on the frame snapshot in the details pane you can step through all captured frames in order.

Keep in mind that, on a web page, a low frame rate isn’t always a problem. When playing a video game the UI is updating constantly, and you’ll need a high frame rate. On a website it’s normal for the frame rate to go down to zero after the initial page load, unless there are ongoing animations.

Как анализировать производительность времени загрузки

Сетевой монитор включает в себя инструмент для анализа производительности загрузки веб-страницы. Чтобы использовать его нужно:

  • кликнуть по иконке «Начать анализ быстродействия», которая расположена в нижней строке состояния;
  • перезагрузить страницу или выполнить сетевой запрос, когда открыт «Сетевой монитор».

В окончательном отчете демонстрируется круговая диаграмма и соответствующая ей таблица полученных ресурсов по типам: JavaScript, CSS, изображения, шрифты и т. д., а также сводка со следующими данными:

  • количество кэшированных ответов;
  • общее количество запросов;
  • размер;
  • размер передачи;
  • время загрузки.

Веб-страница тестируется с пустым кэшем и с записанным кэшем.

Web Vitals and other timings​

The DevTools Performance tab can also show Web Vitals and User Timing metrics.

The Timings lane also shows the First Paint (FP) and the DomContentLoaded (DCL) and Load (L) events.

Hovering over a layout shift in the Experience lane will highlight the DOM node that changed position on the page, assuming that DOM node still exists. Clicking on the layout shift entry shows additional information like the location the element moved from and to.

The Long Tasks lane shows CPU tasks that take longer than 50ms to run, making the page less responsive to user input. The time in excess of 50ms is counted as blocking time, which is marked using black stripes. This can help you debug the Total Blocking Time metric.

7.1 Getting Help¶

The command line is organized similarly to Git in that it
has a number of sub-commands for each function. You can run
to see all the commands:

$ devtool -h
NOTE: Starting bitbake server...
usage: devtool       <subcommand> ...

OpenEmbedded development tool

options:
  --basepath BASEPATH   Base directory of SDK / build directory
  --bbpath BBPATH       Explicitly specify the BBPATH, rather than getting it from the metadata
  -d, --debug           Enable debug output
  -q, --quiet           Print only errors
  --color COLOR         Colorize output (where COLOR is auto, always, never)
  -h, --help            show this help message and exit

subcommands:
  Beginning work on a recipe:
    add                   Add a new recipe
    modify                Modify the source for an existing recipe
    upgrade               Upgrade an existing recipe
  Getting information:
    status                Show workspace status
    latest-version        Report the latest version of an existing recipe
    check-upgrade-status  Report upgradability for multiple (or all) recipes
    search                Search available recipes
  Working on a recipe in the workspace:
    build                 Build a recipe
    rename                Rename a recipe file in the workspace
    edit-recipe           Edit a recipe file
    find-recipe           Find a recipe file
    configure-help        Get help on configure script options
    update-recipe         Apply changes from external source tree to recipe
    reset                 Remove a recipe from your workspace
    finish                Finish working on a recipe in your workspace
  Testing changes on target:
    deploy-target         Deploy recipe output files to live target machine
    undeploy-target       Undeploy recipe output files in live target machine
    build-image           Build image including workspace recipe packages
  Advanced:
    create-workspace      Set up workspace in an alternative location
    extract               Extract the source for an existing recipe
    sync                  Synchronize the source tree for an existing recipe
    menuconfig            Alter build-time configuration for a recipe
    import                Import exported tar archive into workspace
    export                Export workspace into a tar archive
  other:
    selftest-reverse      Reverse value (for selftest)
    pluginfile            Print the filename of this plugin
    bbdir                 Print the BBPATH directory of this plugin
    count                 How many times have this plugin been registered.
    multiloaded           How many times have this plugin been initialized
Use devtool <subcommand> --help to get help on a specific command

As directed in the general help output, you can
get more syntax on a specific command by providing the command name and
using :

Гость форума
От: admin

Эта тема закрыта для публикации ответов.