permissive eslint rules to remove linter warnings
This commit is contained in:
@@ -1,8 +1,5 @@
|
||||
/* eslint "@typescript-eslint/no-var-requires": 0 */
|
||||
const Application = require('spectron').Application;
|
||||
/* eslint "@typescript-eslint/no-var-requires": 0 */
|
||||
const electronPath = require('electron'); // Require Electron from the binaries included in node_modules.
|
||||
/* eslint "@typescript-eslint/no-var-requires": 0 */
|
||||
const path = require('path');
|
||||
|
||||
export default function setup(): void {
|
||||
|
||||
@@ -6,13 +6,11 @@ import commonSetup from './common-setup';
|
||||
describe('angular-electron App', function () {
|
||||
commonSetup.apply(this);
|
||||
|
||||
/* eslint "@typescript-eslint/no-explicit-any": 0 */
|
||||
let browser: any;
|
||||
let client: SpectronClient;
|
||||
|
||||
beforeEach(function () {
|
||||
client = this.app.client;
|
||||
/* eslint "@typescript-eslint/no-explicit-any": 0 */
|
||||
browser = client as any;
|
||||
});
|
||||
|
||||
@@ -21,7 +19,6 @@ describe('angular-electron App', function () {
|
||||
expect(text).to.equal('App works !');
|
||||
});
|
||||
|
||||
|
||||
it('creates initial windows', async function () {
|
||||
const count = await client.getWindowCount();
|
||||
expect(count).to.equal(1);
|
||||
|
||||
@@ -15,5 +15,10 @@
|
||||
"parserOptions": {
|
||||
"tsconfigRootDir": "."
|
||||
},
|
||||
"plugins": ["@typescript-eslint"]
|
||||
"plugins": ["@typescript-eslint"],
|
||||
"rules": {
|
||||
"@typescript-eslint/no-empty-function": 0,
|
||||
"@typescript-eslint/no-var-requires": 0,
|
||||
"@typescript-eslint/no-explicit-any": 0
|
||||
}
|
||||
}
|
||||
|
||||
1
main.ts
1
main.ts
@@ -24,7 +24,6 @@ function createWindow(): BrowserWindow {
|
||||
});
|
||||
|
||||
if (serve) {
|
||||
/* eslint "@typescript-eslint/no-var-requires": 0 */
|
||||
require('electron-reload')(__dirname, {
|
||||
electron: require(`${__dirname}/node_modules/electron`)
|
||||
});
|
||||
|
||||
14
package.json
14
package.json
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "angular-electron",
|
||||
"version": "6.3.1",
|
||||
"version": "6.4.0",
|
||||
"description": "Angular 8 with Electron (Typescript + SASS + Hot Reload)",
|
||||
"homepage": "https://github.com/maximegris/angular-electron",
|
||||
"author": {
|
||||
@@ -12,6 +12,8 @@
|
||||
"angular 8",
|
||||
"electron",
|
||||
"typescript",
|
||||
"eslint",
|
||||
"spectron",
|
||||
"sass"
|
||||
],
|
||||
"main": "main.js",
|
||||
@@ -56,8 +58,8 @@
|
||||
"@types/jasminewd2": "2.0.6",
|
||||
"@types/mocha": "5.2.7",
|
||||
"@types/node": "12.6.8",
|
||||
"@typescript-eslint/eslint-plugin": "^2.7.0",
|
||||
"@typescript-eslint/parser": "^2.7.0",
|
||||
"@typescript-eslint/eslint-plugin": "2.8.0",
|
||||
"@typescript-eslint/parser": "2.8.0",
|
||||
"chai": "4.2.0",
|
||||
"codelyzer": "5.1.0",
|
||||
"conventional-changelog-cli": "2.0.25",
|
||||
@@ -65,13 +67,13 @@
|
||||
"electron": "7.1.1",
|
||||
"electron-builder": "21.2.0",
|
||||
"electron-reload": "1.5.0",
|
||||
"eslint": "^6.6.0",
|
||||
"eslint-plugin-import": "^2.18.2",
|
||||
"eslint": "6.6.0",
|
||||
"eslint-plugin-import": "2.18.2",
|
||||
"jasmine-core": "3.4.0",
|
||||
"jasmine-spec-reporter": "4.2.1",
|
||||
"karma": "4.2.0",
|
||||
"karma-coverage-istanbul-reporter": "2.1.0",
|
||||
"karma-electron": "^6.3.0",
|
||||
"karma-electron": "6.3.0",
|
||||
"karma-jasmine": "2.0.1",
|
||||
"karma-jasmine-html-reporter": "1.4.2",
|
||||
"mocha": "6.2.0",
|
||||
|
||||
@@ -7,10 +7,8 @@ import { Component, OnInit } from '@angular/core';
|
||||
})
|
||||
export class HomeComponent implements OnInit {
|
||||
|
||||
/* eslint "no-empty-function":0, "@typescript-eslint/no-empty-function": 0 */
|
||||
constructor() { }
|
||||
|
||||
/* eslint "no-empty-function":0, "@typescript-eslint/no-empty-function": 0 */
|
||||
ngOnInit(): void { }
|
||||
|
||||
}
|
||||
|
||||
@@ -6,9 +6,7 @@ import { Component, OnInit } from '@angular/core';
|
||||
styleUrls: ['./page-not-found.component.scss']
|
||||
})
|
||||
export class PageNotFoundComponent implements OnInit {
|
||||
/* eslint "no-empty-function":0, "@typescript-eslint/no-empty-function": 0 */
|
||||
constructor() {}
|
||||
|
||||
/* eslint "no-empty-function":0, "@typescript-eslint/no-empty-function": 0 */
|
||||
ngOnInit(): void {}
|
||||
}
|
||||
|
||||
@@ -4,6 +4,5 @@ import { Directive } from '@angular/core';
|
||||
selector: 'webview'
|
||||
})
|
||||
export class WebviewDirective {
|
||||
/* eslint "no-empty-function":0, "@typescript-eslint/no-empty-function": 0 */
|
||||
constructor() {}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,6 @@ import {
|
||||
platformBrowserDynamicTesting
|
||||
} from '@angular/platform-browser-dynamic/testing';
|
||||
|
||||
/* eslint "@typescript-eslint/no-explicit-any":0 */
|
||||
declare const require: any;
|
||||
|
||||
// First, initialize the Angular testing environment.
|
||||
|
||||
Reference in New Issue
Block a user