Skip to content

Commit 6079a31

Browse files
committed
Add individual exceptions for unused vars
The alternative of turning off noUnusedLocals is not desirable since we still want to catch unused imports which is done by the same rule. This is the same reason why no-unused-vars is enabled in ESLint with exceptions in the lines below each change.
1 parent 7e4b935 commit 6079a31

File tree

1 file changed

+7
-1
lines changed
  • static-site/src/components/ListResources

1 file changed

+7
-1
lines changed

static-site/src/components/ListResources/Modal.tsx

+7-1
Original file line numberDiff line numberDiff line change
@@ -239,9 +239,11 @@ function _draw(ref, data) {
239239
.attr("cy", (d) => heights.height - heights.marginBelowAxis - heights.marginAboveAxis - radius - padding - d.y)
240240
.attr("r", radius)
241241
.attr('fill', color)
242+
// @ts-expect-error
242243
.on("mouseover", function(e, d) {
243244
/* lower opacity of non-hovered, increase radius of hovered circle */
244245
beeswarm.join(
246+
// @ts-expect-error
245247
(enter) => {}, /* eslint-disable-line */
246248
(update) => selectSnapshot(update, d)
247249
)
@@ -261,13 +263,15 @@ function _draw(ref, data) {
261263
})
262264
.on("mouseleave", function() {
263265
beeswarm.join(
266+
// @ts-expect-error
264267
(enter) => {}, /* eslint-disable-line */
265268
(update) => resetBeeswarm(update)
266269
)
267270
/* hide the vertical line + text which appeared on mouseover */
268271
selectedVersionGroup.selectAll("*")
269272
.style("opacity", 0)
270273
})
274+
// @ts-expect-error
271275
.on("click", function(e, d) {
272276
window.open(`/${data.name}@${d.data.version}`,'_blank'); // TEST!
273277
})
@@ -288,7 +292,8 @@ function _draw(ref, data) {
288292
.on("mousemove", function(e) {
289293
const { datum, hoveredDateStr } = getVersion(e);
290294
beeswarm.join(
291-
(enter) => {}, /* eslint-disable-line */
295+
// @ts-expect-error
296+
(enter) => {}, /* eslint-disable-line */
292297
(update) => selectSnapshot(update, datum)
293298
)
294299
/* update the vertical line + text which appears on hover */
@@ -308,6 +313,7 @@ function _draw(ref, data) {
308313
})
309314
.on("mouseleave", function() {
310315
beeswarm.join(
316+
// @ts-expect-error
311317
(enter) => {}, /* eslint-disable-line */
312318
(update) => resetBeeswarm(update)
313319
)

0 commit comments

Comments
 (0)