A boilerplate for creating projects that want to use typeorm with sqlite3 inside electron.
The main idea of this stack is to use TypeORM on main process and communicate with renderer process by usage of remote/ipc calls.
OS | Status |
---|---|
Windows | ✔️ |
Linux | ✔️ |
Mac | ✔️ |
npm start
Starts your app in development mode using the same terminal for electron and webpack-dev-server
npm build
Bundles your app using production config.
npm run build:dev
Bundles your app using development config.
npm run package
Packages your app using electron-builder (config can be found in ./electron-builder.json)
npm run start:dev
Starts webpack-dev-server.
npm run start:electron
Starts electron instance in development mode.
- Webpack-dev-server doesn't notice any changes I make to code.
- React-hot-loader doesn't work.
Make sure that you have enough watchers.
- Webpack warns about not being able to find database drivers in console.
TypeORM has conditional dependencies on other databases (mysql, mssql...) and webpack has no idea which one are needed and tries to load all of them and warnings pop out.