New issue
Advanced search Search tips

Issue 664213 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Feature



Sign in to add a comment

Add EventListener.once to DevTools protocol

Project Member Reported by ericbidelman@chromium.org, Nov 10 2016

Issue description

For Lighthouse, we'd like to add an audit that recommends single-use event listeners ({once: true}) where appropriate. To make this easier to verify, it would be nice for the 
EventListener interface to have a `once` property to check against.

The DevTools protocol already has a `passive` flag for passive event listeners. Can we add a flag for `once` too?
 
Components: Blink>DOM>Events
Owner: dtapu...@chromium.org
Status: Assigned (was: Untriaged)
Labels: -Type-Bug Type-Feature
Patch posted here: 
https://codereview.chromium.org/2490303003

just need to get the devtools team to review it...
Status: Fixed (was: Assigned)
Labels: Hotlist-Input-Dev M056
Labels: -M056 M-56
Project Member

Comment 7 by bugdroid1@chromium.org, Nov 11 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/311048bddd4ce2d5936b1d813b95a9a59c2ed674

commit 311048bddd4ce2d5936b1d813b95a9a59c2ed674
Author: dtapuska <dtapuska@chromium.org>
Date: Fri Nov 11 20:42:41 2016

Add once field to devtools so it can be queried by lighthouse.

Allow the once field property on EventListener to be queried
from the command line and devtools protocol.

BUG= 664213 

Review-Url: https://codereview.chromium.org/2490303003
Cr-Commit-Position: refs/heads/master@{#431630}

[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/http/tests/inspector/elements/event-listeners-framework-with-service-worker-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/console/command-line-api-getEventListeners-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/console/command-line-api-getEventListeners.html
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar-custom-framework-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar-custom-framework.html
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar-jquery1-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar-jquery2-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listener-sidebar.html
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listeners-about-blank-expected.txt
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/LayoutTests/inspector/elements/event-listeners-about-blank.html
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/bindings/core/v8/V8EventListenerInfo.h
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/core/inspector/InspectorDOMDebuggerAgent.cpp
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/core/inspector/ThreadDebugger.cpp
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/core/inspector/browser_protocol.json
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/devtools/front_end/components/EventListenersUtils.js
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/devtools/front_end/components/EventListenersView.js
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/devtools/front_end/sdk/RemoteObject.js
[modify] https://crrev.com/311048bddd4ce2d5936b1d813b95a9a59c2ed674/third_party/WebKit/Source/devtools/front_end/sdk/RuntimeModel.js

Comment 8 by tkent@chromium.org, Mar 15 2017

Components: -Blink>DOM>Events Blink>DOM
Remove Blink>DOM>Events

Sign in to add a comment