Skip to content

Commit

Permalink
update: eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
Enubia committed Nov 23, 2023
1 parent dacef15 commit 9f5c032
Show file tree
Hide file tree
Showing 6 changed files with 281 additions and 11 deletions.
7 changes: 6 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{
"extends": ["slurp-config", "slurp-config/vue"]
"extends": ["slurp-config", "slurp-config/vue"],

"env": {
"browser": true,
"node": true
}
}
6 changes: 3 additions & 3 deletions electron/main/ipcEvents.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { BrowserWindow, ipcMain } from 'electron';
import { BrowserWindow, ipcMain, IpcMainEvent, Rectangle } from 'electron';
import log from 'electron-log';
import ElectronStore from 'electron-store';

Expand Down Expand Up @@ -27,7 +27,7 @@ export default class IpcEvents {
}

private rerender() {
ipcMain.on(IpcEvent.Rerender, (_event: Electron.IpcMainEvent, args: 'child' | 'parent') => {
ipcMain.on(IpcEvent.Rerender, (_event: IpcMainEvent, args: 'child' | 'parent') => {
log.info('Rerendering', args);

if (args === 'child' && this.settings) {
Expand Down Expand Up @@ -71,7 +71,7 @@ export default class IpcEvents {
ipcMain.on(IpcEvent.Vanish, () => {
log.info('Vanishing overlay');

const windowBounds = this.overlay?.getBounds() as Electron.Rectangle;
const windowBounds = this.overlay?.getBounds() as Rectangle;

log.info('Saved window state', windowBounds);

Expand Down
4 changes: 2 additions & 2 deletions electron/main/window/overlay.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { app, BrowserWindow, nativeTheme, shell } from 'electron';
import { app, BrowserWindow, nativeTheme, shell, WebPreferences } from 'electron';
import log from 'electron-log';
import ElectronStore from 'electron-store';

Expand All @@ -15,7 +15,7 @@ export default class Overlay {

log.info('Overlay window state', windowState);

const webPreferences: Electron.WebPreferences = {
const webPreferences: WebPreferences = {
webviewTag: true,
nodeIntegration: true,
contextIsolation: false,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"electron-store": "8.1.0",
"electron-unhandled": "4.0.1",
"electron-updater": "6.1.4",
"eslint-config-slurp-config": "2.2.0",
"eslint-config-slurp-config": "2.3.0",
"husky": "8.0.3",
"lint-staged": "15.1.0",
"release-it": "17.0.0",
Expand Down
Loading

0 comments on commit 9f5c032

Please sign in to comment.