Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Electron up to 34 #2175

Merged
merged 3 commits into from
Jan 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions application/apps/rustcore/ts-bindings/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import globals from "globals";
import tsParser from "@typescript-eslint/parser";
import path from "node:path";
import { fileURLToPath } from "node:url";
import js from "@eslint/js";
import { FlatCompat } from "@eslint/eslintrc";

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
});

export default [{
ignores: ["dist/**/*", "spec/**/*"],
}, ...compat.extends("eslint:recommended", "plugin:@typescript-eslint/recommended"), {
plugins: {
"@typescript-eslint": typescriptEslint,
},

languageOptions: {
globals: {
...globals.browser,
},

parser: tsParser,
ecmaVersion: "latest",
sourceType: "module",
},

rules: {
"no-control-regex": "off",

"@typescript-eslint/no-unused-vars": ["error", {
"argsIgnorePattern": "^_",
"varsIgnorePattern": "^_",
"caughtErrorsIgnorePattern": "^_"
}],
"@typescript-eslint/no-this-alias": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-empty-interface": "off",
"@typescript-eslint/no-inferrable-types": "off",
"@typescript-eslint/no-unsafe-declaration-merging": "off",
"@typescript-eslint/no-unused-expressions": "off",
"@typescript-eslint/no-empty-object-type": "off"

},
}];
30 changes: 15 additions & 15 deletions application/apps/rustcore/ts-bindings/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,38 +8,38 @@
"build": "node_modules/.bin/tsc -p tsconfig.json",
"prod": "node_modules/.bin/tsc -p tsconfig.json",
"test_cancel": "node_modules/.bin/electron node_modules/jasmine-ts/lib/index.js ./spec/session.cancel.spec.ts",
"lint": "node_modules/.bin/eslint . --ext .ts --max-warnings=0",
"lint": "node_modules/.bin/eslint . --max-warnings=0",
"check": "node_modules/.bin/tsc -p tsconfig.json --noemit"
},
"author": "Dmitry Astafyev",
"contributors": [],
"license": "MIT",
"devDependencies": {
"@types/jasmine": "^5.1.4",
"@types/node": "^20.7.0",
"@types/jasmine": "^5.1.5",
"@types/node": "^22.10.10",
"@types/tmp": "^0.2.4",
"@types/uuid": "^9.0.4",
"@typescript-eslint/eslint-plugin": "^7.2.0",
"@typescript-eslint/parser": "^7.2.0",
"@types/uuid": "^10.0.0",
"@typescript-eslint/eslint-plugin": "^8.21.0",
"@typescript-eslint/parser": "^8.21.0",
"custom.stdout": "^1.0.2",
"electron": "^30.0.6",
"electron": "^34.0.1",
"electron-build-env": "0.2.0",
"electron-rebuild": "^3.2.5",
"eslint": "^8.50.0",
"eslint-plugin-import": "^2.28.1",
"eslint": "^9.18.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-promise": "^6.0.0",
"jasmine": "^5.1.0",
"loglevel": "^1.6.6",
"eslint-plugin-promise": "^7.2.1",
"jasmine": "^5.5.0",
"loglevel": "^1.9.2",
"tmp": "^0.2.3",
"ts-node": "^10.4.0",
"typescript": "5.1.6"
"typescript": "^5.7.3"
},
"dependencies": {
"platform": "link:../../../platform",
"protocol": "link:../../protocol/pkg",
"tslib": "^2.6.2",
"uuid": "^9.0.1"
"tslib": "^2.8.1",
"uuid": "^11.0.5"
},
"packageManager": "[email protected]"
}
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class SessionStream {
return this._session.sendIntoSde(operation, request).then((response) => {
try {
return response;
} catch (e) {
} catch (_err) {
return Promise.reject(new Error(`Fail to parse response`));
}
});
Expand Down
1 change: 1 addition & 0 deletions application/apps/rustcore/ts-bindings/src/native/native.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ export function getNativeModule(): IRustModuleExports {
throw new Error(`Fail to find modules in:\n${paths.join('\n')}`);
})();
scope.getLogger('Native module getter').verbose(`Target: ${modulePath}`);
// eslint-disable-next-line @typescript-eslint/no-require-imports
return require(modulePath);
}

Expand Down
Loading
Loading