Skip to content

Commit

Permalink
eslint-plugin-sonarjs was removed due to too strong an impact on buil…
Browse files Browse the repository at this point in the history
…d performance and too low an impact
  • Loading branch information
ilyhalight committed Nov 4, 2024
1 parent 97dae13 commit 126fdcc
Show file tree
Hide file tree
Showing 8 changed files with 2,463 additions and 10,613 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
node-version: ${{ matrix.node-version }}
- name: Install 🔧
shell: bash
run: npm install --legacy-peer-deps
run: npm install
- name: Build 🔧
run: npm run build
- name: Upload Artifact 🚀
Expand Down
12 changes: 6 additions & 6 deletions dist/vot.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -10084,17 +10084,16 @@ class VideoHandler {
this.votSettingsDialog.container.hidden =
!this.votSettingsDialog.container.hidden;
if (document.fullscreenElement || document.webkitFullscreenElement) {
// eslint-disable-next-line sonarjs/no-unused-expressions
document.webkitExitFullscreen && document.webkitExitFullscreen();
// eslint-disable-next-line sonarjs/no-unused-expressions
document.exitFullscreen && document.exitFullscreen();
}
});

this.votVideoVolumeSlider.input.addEventListener("input", (e) => {
const value = Number(e.target.value);
this.votVideoVolumeSlider.label.querySelector("strong").textContent =
`${value}%`;
this.votVideoVolumeSlider.label.querySelector(
"strong",
).textContent = `${value}%`;
this.setVideoVolume(value / 100);
if (this.data.syncVolume) {
this.syncVolumeWrapper("video", value);
Expand Down Expand Up @@ -10941,8 +10940,9 @@ class VideoHandler {
const newSlidersVolume = Math.round(videoVolume);

this.votVideoVolumeSlider.input.value = newSlidersVolume;
this.votVideoVolumeSlider.label.querySelector("strong").textContent =
`${newSlidersVolume}%`;
this.votVideoVolumeSlider.label.querySelector(
"strong",
).textContent = `${newSlidersVolume}%`;
ui.updateSlider(this.votVideoVolumeSlider.input);

if (this.data.syncVolume === 1) {
Expand Down
12 changes: 0 additions & 12 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,32 +1,20 @@
import js from "@eslint/js";
import globals from "globals";
import oxlint from "eslint-plugin-oxlint";
import sonarjs from "eslint-plugin-sonarjs";
// import github from "eslint-plugin-github";

export default [
{
ignores: ["dist/*"],
},
js.configs.recommended,
sonarjs.configs.recommended,
{
// plugins: {
// github: github,
// },
rules: {
"no-control-regex": 0,
"no-async-promise-executor": 0,
"sonarjs/max-switch-cases": 0,
"sonarjs/prefer-for-of": 0,
"sonarjs/new-cap": 0,
"sonarjs/todo-tag": "warn",
"sonarjs/no-commented-code": 0,
"sonarjs/no-nested-assignment": 0,
"sonarjs/cognitive-complexity": "warn",
"sonarjs/slow-regex": 0,
// sonarjs/sonar-no-fallthrough crashed in 2.0.1
"sonarjs/sonar-no-fallthrough": 0,
// return after update github eslint plugin to full support eslint 9
// "github/no-innerText": "error",
// "github/no-inner-html": "error",
Expand Down
Loading

0 comments on commit 126fdcc

Please sign in to comment.