install electron-forge
This commit is contained in:
parent
e6ffde7b5e
commit
1b345af4ca
|
@ -9,3 +9,4 @@ node_modules
|
|||
|
||||
# generated code
|
||||
dist
|
||||
.webpack
|
||||
|
|
File diff suppressed because it is too large
Load Diff
37
package.json
37
package.json
|
@ -4,22 +4,47 @@
|
|||
"description": ".",
|
||||
"private": true,
|
||||
"author": "Xymorot",
|
||||
"main": "./.webpack/main",
|
||||
"scripts": {
|
||||
"start": "electron ./dist/main.js",
|
||||
"start": "electron-forge start",
|
||||
"build": "tsc",
|
||||
"watch": "tsc -w",
|
||||
"tslint-check": "tslint-config-prettier-check ./tslint.json",
|
||||
"tslint": "tslint -t stylish -c tslint.json -p tsconfig.json",
|
||||
"prettier": "prettier -c **/*.{html,{c,sc,sa,le}ss,yml}"
|
||||
},
|
||||
"dependencies": {
|
||||
"electron": "^2.0.18",
|
||||
"typescript": "^2.9.2"
|
||||
},
|
||||
"dependencies": {},
|
||||
"devDependencies": {
|
||||
"@electron-forge/cli": "^6.0.0-beta.39",
|
||||
"@electron-forge/plugin-webpack": "^6.0.0-beta.39",
|
||||
"@marshallofsound/webpack-asset-relocator-loader": "^0.5.0",
|
||||
"electron": "^2.0.18",
|
||||
"prettier": "^1.18.2",
|
||||
"tslint": "^5.17.0",
|
||||
"tslint-config-prettier": "^1.18.0",
|
||||
"tslint-plugin-prettier": "^2.0.1"
|
||||
"tslint-plugin-prettier": "^2.0.1",
|
||||
"typescript": "^2.9.2"
|
||||
},
|
||||
"config": {
|
||||
"forge": {
|
||||
"plugins": [
|
||||
[
|
||||
"@electron-forge/plugin-webpack",
|
||||
{
|
||||
"mainConfig": "./webpack.main.config.js",
|
||||
"renderer": {
|
||||
"config": "./webpack.renderer.config.js",
|
||||
"entryPoints": [
|
||||
{
|
||||
"html": "./index.html",
|
||||
"js": "./dist/renderer.js",
|
||||
"name": "main_window"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,10 +4,8 @@
|
|||
"rules": {
|
||||
"prettier": true,
|
||||
"no-console": true,
|
||||
"object-literal-sort-keys": [
|
||||
true,
|
||||
"match-declaration-order-only"
|
||||
]
|
||||
"object-literal-sort-keys": [true, "match-declaration-order-only"],
|
||||
"no-implicit-dependencies": [true, "dev"]
|
||||
},
|
||||
"linterOptions": {
|
||||
"exclude": ["node_modules", "dist"]
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
module.exports = {
|
||||
/**
|
||||
* This is the main entry point for your application, it's the first file
|
||||
* that runs in the main process.
|
||||
*/
|
||||
entry: './dist/main.js',
|
||||
// Put your normal webpack config below here
|
||||
module: {
|
||||
rules: require('./webpack.rules'),
|
||||
},
|
||||
};
|
|
@ -0,0 +1,6 @@
|
|||
module.exports = {
|
||||
// Put your normal webpack config below here
|
||||
module: {
|
||||
rules: require('./webpack.rules'),
|
||||
},
|
||||
};
|
|
@ -0,0 +1,33 @@
|
|||
module.exports = [
|
||||
// Add support for native node modules
|
||||
{
|
||||
test: /\.node$/,
|
||||
use: 'node-loader',
|
||||
},
|
||||
{
|
||||
test: /\.(m?js|node)$/,
|
||||
parser: { amd: false },
|
||||
use: {
|
||||
loader: '@marshallofsound/webpack-asset-relocator-loader',
|
||||
options: {
|
||||
outputAssetBase: 'native_modules',
|
||||
},
|
||||
},
|
||||
},
|
||||
// Put your webpack loader rules in this array. This is where you would put
|
||||
// your ts-loader configuration for instance:
|
||||
/**
|
||||
* Typescript Example:
|
||||
*
|
||||
* {
|
||||
* test: /\.tsx?$/,
|
||||
* exclude: /(node_modules|.webpack)/,
|
||||
* loaders: [{
|
||||
* loader: 'ts-loader',
|
||||
* options: {
|
||||
* transpileOnly: true
|
||||
* }
|
||||
* }]
|
||||
* }
|
||||
*/
|
||||
];
|
Loading…
Reference in New Issue