@zwa73/dev-utils 1.0.59 → 1.0.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/data/CreateElectronFrame/.eslintrc.js +41 -0
- package/data/CreateElectronFrame/forge.config.ts +52 -0
- package/data/CreateElectronFrame/package-lock.json +23687 -0
- package/data/CreateElectronFrame/package.json +59 -0
- package/data/CreateElectronFrame/src/Component/Base.tsx +8 -0
- package/data/CreateElectronFrame/src/Component/index.ts +1 -0
- package/data/CreateElectronFrame/src/Static/index.ts +14 -0
- package/data/CreateElectronFrame/src/app.tsx +7 -0
- package/data/CreateElectronFrame/src/index.html +20 -0
- package/data/CreateElectronFrame/src/index.ts +86 -0
- package/data/CreateElectronFrame/src/preload.ts +2 -0
- package/data/CreateElectronFrame/src/renderer.ts +2 -0
- package/data/CreateElectronFrame/webpack.main.config.ts +20 -0
- package/data/CreateElectronFrame/webpack.plugins.ts +9 -0
- package/data/CreateElectronFrame/webpack.renderer.config.ts +23 -0
- package/data/CreateElectronFrame/webpack.rules.ts +41 -0
- package/dist/Command/CreateElectronFrame.d.ts +3 -0
- package/dist/Command/CreateElectronFrame.js +63 -0
- package/dist/Command/Init.js +3 -2
- package/dist/Command/Route.js +2 -0
- package/package.json +1 -1
- package/src/Command/CreateElectronFrame.ts +40 -0
- package/src/Command/Init.ts +8 -2
- package/src/Command/Route.ts +2 -0
- /package/data/{index.d.ts → init/index.d.ts} +0 -0
- /package/data/{index.js → init/index.js} +0 -0
- /package/data/{scripts → init/scripts}/compile.ps1 +0 -0
- /package/data/{scripts → init/scripts}/watch.ps1 +0 -0
- /package/data/{src → init/src}/index.ts +0 -0
@@ -0,0 +1,41 @@
|
|
1
|
+
/**
|
2
|
+
{
|
3
|
+
"env": {
|
4
|
+
"browser": true,
|
5
|
+
"es6": true,
|
6
|
+
"node": true
|
7
|
+
},
|
8
|
+
"extends": [
|
9
|
+
"eslint:recommended",
|
10
|
+
"plugin:@typescript-eslint/eslint-recommended",
|
11
|
+
"plugin:@typescript-eslint/recommended",
|
12
|
+
"plugin:import/recommended",
|
13
|
+
"plugin:import/electron",
|
14
|
+
"plugin:import/typescript"
|
15
|
+
],
|
16
|
+
"parser": "@typescript-eslint/parser"
|
17
|
+
}
|
18
|
+
*/
|
19
|
+
module.exports = {
|
20
|
+
env: {
|
21
|
+
browser: true,
|
22
|
+
es6: true,
|
23
|
+
node: true
|
24
|
+
},
|
25
|
+
parser: "@typescript-eslint/parser",
|
26
|
+
parserOptions: { project: "tsconfig.json" },
|
27
|
+
plugins: ["@typescript-eslint"],
|
28
|
+
ignorePatterns: ["webpack.*","*.js", "dist/**"],
|
29
|
+
overrides: [
|
30
|
+
{
|
31
|
+
files: [
|
32
|
+
"src/**/*.{ts,tsx}"
|
33
|
+
],
|
34
|
+
rules: {
|
35
|
+
semi: ["error", "always"],
|
36
|
+
"@typescript-eslint/promise-function-async": "error",
|
37
|
+
"@typescript-eslint/no-floating-promises": "error",
|
38
|
+
},
|
39
|
+
},
|
40
|
+
],
|
41
|
+
};
|
@@ -0,0 +1,52 @@
|
|
1
|
+
import type { ForgeConfig } from '@electron-forge/shared-types';
|
2
|
+
import { MakerSquirrel } from '@electron-forge/maker-squirrel';
|
3
|
+
import { MakerZIP } from '@electron-forge/maker-zip';
|
4
|
+
import { MakerDeb } from '@electron-forge/maker-deb';
|
5
|
+
import { MakerRpm } from '@electron-forge/maker-rpm';
|
6
|
+
import { AutoUnpackNativesPlugin } from '@electron-forge/plugin-auto-unpack-natives';
|
7
|
+
import { WebpackPlugin } from '@electron-forge/plugin-webpack';
|
8
|
+
import { FusesPlugin } from '@electron-forge/plugin-fuses';
|
9
|
+
import { FuseV1Options, FuseVersion } from '@electron/fuses';
|
10
|
+
|
11
|
+
import { mainConfig } from './webpack.main.config';
|
12
|
+
import { rendererConfig } from './webpack.renderer.config';
|
13
|
+
|
14
|
+
const config: ForgeConfig = {
|
15
|
+
packagerConfig: {
|
16
|
+
asar: true,
|
17
|
+
},
|
18
|
+
rebuildConfig: {},
|
19
|
+
makers: [new MakerSquirrel({}), new MakerZIP({}, ['darwin']), new MakerRpm({}), new MakerDeb({})],
|
20
|
+
plugins: [
|
21
|
+
new AutoUnpackNativesPlugin({}),
|
22
|
+
new WebpackPlugin({
|
23
|
+
mainConfig,
|
24
|
+
renderer: {
|
25
|
+
config: rendererConfig,
|
26
|
+
entryPoints: [
|
27
|
+
{
|
28
|
+
html: './src/index.html',
|
29
|
+
js: './src/renderer.ts',
|
30
|
+
name: 'main_window',
|
31
|
+
preload: {
|
32
|
+
js: './src/preload.ts',
|
33
|
+
},
|
34
|
+
},
|
35
|
+
],
|
36
|
+
},
|
37
|
+
}),
|
38
|
+
// Fuses are used to enable/disable various Electron functionality
|
39
|
+
// at package time, before code signing the application
|
40
|
+
new FusesPlugin({
|
41
|
+
version: FuseVersion.V1,
|
42
|
+
[FuseV1Options.RunAsNode]: false,
|
43
|
+
[FuseV1Options.EnableCookieEncryption]: true,
|
44
|
+
[FuseV1Options.EnableNodeOptionsEnvironmentVariable]: false,
|
45
|
+
[FuseV1Options.EnableNodeCliInspectArguments]: false,
|
46
|
+
[FuseV1Options.EnableEmbeddedAsarIntegrityValidation]: true,
|
47
|
+
[FuseV1Options.OnlyLoadAppFromAsar]: true,
|
48
|
+
}),
|
49
|
+
],
|
50
|
+
};
|
51
|
+
|
52
|
+
export default config;
|