Let’s tak a step ahead in our journey toward the target of this notes that is, how to build an HMI runnable on different platforms using some Web Technologies.
The first step is to rearrange our project in order to introduce TypeScript.
'../index.html'
{
"compilerOptions": {
"target": "es5",
"module": "commonjs",
"moduleResolution": "node",
"noImplicitAny": false,
"sourceMap": true,
"outDir": "dist",
"baseUrl": ".",
"paths": {
"*": [
"node_modules/*"
]
}
},
"include": [
"src/**/*"
]
}
"build": "tsc",
and then we need to modify a little our start script as follows:
"start": "npm run build && electron ./dist/main.js"
so that, in a few words, it will initially compile our TypeScript project, and then launch the application passing to the electron command the resulting main.js file.
The code written for this note is available for consulting and comments on my GitHub Repository at the following link.
For now that’s all folks.
Enjoy, 😉