Просто тестовое приложение на Electron
This repository has been archived on 2026-06-18. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
  • TypeScript 64.9%
  • HTML 17.1%
  • JavaScript 11.3%
  • Less 6.7%
Find a file
Жора Змейкин 8eac22c301
Fix package.json
2023-02-05 16:37:08 +04:00
src Release 1.0.0 2023-02-05 14:53:18 +04:00
.eslintignore Release 1.0.0 2023-02-05 14:53:18 +04:00
.eslintrc.json Release 1.0.0 2023-02-05 14:53:18 +04:00
.gitignore Release 1.0.0 2023-02-05 14:53:18 +04:00
.htmlhintrc.json Release 1.0.0 2023-02-05 14:53:18 +04:00
.stylelintrc.json Release 1.0.0 2023-02-05 14:53:18 +04:00
forge.config.js Release 1.0.0 2023-02-05 14:53:18 +04:00
package.json Fix package.json 2023-02-05 16:37:08 +04:00
README.md Documentation and package.json update 2023-02-05 16:32:12 +04:00
tsconfig-checks.json Release 1.0.0 2023-02-05 14:53:18 +04:00
tsconfig-general.json Release 1.0.0 2023-02-05 14:53:18 +04:00
tsconfig-node.json Release 1.0.0 2023-02-05 14:53:18 +04:00
tsconfig-web.json Release 1.0.0 2023-02-05 14:53:18 +04:00
yarn.lock Release 1.0.0 2023-02-05 14:53:18 +04:00

Test Electron app

A typical Electron test application that just runs. It can be compiled almost under Windows and Linux platform (deb, rpm, AppImage, .tar.gz)

Application preparation

To start this application, you need to do a little preparation:

  1. Install Node.js LTS (at the time of writing this documentation it is v18.14.0)
  2. Run the command corepack enable to bring up the yarn command, you may need administrator rights.
  3. In the folder with the project, run the command yarn install, this will install all the necessary modules to work.
  4. Compile the TypeScript files:
    1. Run yarn run tsc_build_node
    2. Run yarn run tsc_build_web
  5. Compile the Less files:
    1. Run yarn run less_build

Launching the program

To start the program, type the command yarn run start. This method is only suitable for testing, if you want to use the program later it is better to compile it.

Compiling the program

To compile the program for your operating system run: yarn run build. All compiled files are stored in the dist/ folder. The program can also be compiled for other operating systems, for example:

  • Compilation for Windows: yarn run build_win
  • Compilation for Linux: yarn run build_linux <type>

Where <type> you must specify the file you want to output. For example, you could specify AppImage or rpm. Supported values are: AppImage, tar.gz, snap, rpm, deb. Example command:

  • yarn run build_linux AppImage

If you can't make up your mind, we recommend leaving this field blank. This will create a zip archive and a linux-unpacked/ folder with a binary to run the program.

In addition, different processor architectures are supported. By default it compiles according to your architecture, but you can change this behavior by adding an optional argument after the command. Compiling for x64, ia32, armv7l and arm64 architectures is supported. For example:

  • Compilation under arm64 for Windows: yarn run build_win --arm64
  • Compilation under x64 for linux: yarn run build_linux --x64
  • And so on...

Note: compiling a program is not a quick thing, please be patient. Also during the compilation the program will download additional packages required for compilation.

Note 2: Packaged programs in .exe, .deb, .rpm and similar will take longer to run because it takes time to unpack and run them. Startup speed can be improved by running programs from the win-unpacked/ or linux-unpacked/ folders.