BenoitHanotte commented on a change in pull request #15423:
URL: https://github.com/apache/airflow/pull/15423#discussion_r619885706
##########
File path: airflow/www/static/js/calendar.js
##########
@@ -0,0 +1,269 @@
+/* eslint-disable func-names */
+/* eslint-disable no-underscore-dangle */
Review comment:
I removed the second one, but disabling `func-names` is required to be
able to use d3-tip as:
```
.on('mouseover', function (data) {
const tt = tipHtml(data);
dayTip.direction('n');
dayTip.show(tt, this);
})
.on('mouseout', function (data) {
dayTip.hide(data, this);
});
```
Using arrow-style functions won't work for some reason.
Removing `func-names` requires extracting the anonymous functions, but that
also makes the code a bit heavier. I believe this is the reason `func-names` is
currently disabled in `tree.js` as well.
What do you think? should we keep it this way or should we extract the
tooltip functions?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]