-
Notifications
You must be signed in to change notification settings - Fork 22.7k
Lint: migrate function expressions to arrow functions or declarations #39666
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Preview URLs (48 pages)
Flaws (39)Note! 37 documents with no flaws that don't need to be listed. 🎉 URL:
URL:
URL:
URL:
URL:
URL:
URL:
URL:
URL:
URL:
URL:
(comment last updated: 2025-05-27 11:23:17) |
4b5d6e4
to
c4e2fd1
Compare
This pull request has merge conflicts that must be resolved before it can be merged. |
@@ -10,7 +10,7 @@ browser-compat: webextensions.api.contentScriptGlobalScope.cloneInto | |||
This function provides a safe way to take an object defined in a privileged scope and create a [structured clone](/en-US/docs/Web/API/Web_Workers_API/Structured_clone_algorithm) of it in a less-privileged scope. It returns a reference to the clone: | |||
|
|||
```js | |||
var clonedObject = cloneInto(myObject, targetWindow); | |||
const clonedObject = cloneInto(myObject, targetWindow); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI @rebloor, some code style / modernization changes here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
files/en-us/web/css/css_display/multi-keyword_syntax_of_display/index.md
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM me, thanks. Pinged rebloor for a look if you'd like to wait for his +1.
Yes, I'm not particularly confident with the WebExt changes. I will wait for @rebloor's opinions. |
Our coding style guide prescribes the use of arrow functions for callbacks, and function declarations for creating identifier bindings. This PR removes most usage of function expressions.