Skip to content

ACFUN-FOSS/acfun-live-toolbox-MKII

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AcFun Live ToolBox

// test

                     

An AcFun-FOSS project.

请参阅 GIT 使用法

Prerequisite

  • Node.js LTS latest.
  • Yarn ≥ 3.

Setup

1. Setup yarn

First, switch to node.js lts latest.

ℹ️ NOTE: It is reported that switching between different version of node with nvm or something else may needs a restart of shell to take effect.

After that, run

node --version

to check if node is usable.

Then,

cd acfun-live-toolbox-MKII
corepack enable
yarn set version stable

2. Setup development environment variables

⚠ ATTENTION: Every time a new shell session is entered, you should always perform this step once as long as you're gonna download anything with yarn. After perform this step, don't close your terminal window, make sure you run yarn install or yarn add or something else in the same shell session.

Windows (CMD):

CALL dev-tools\setup_dev_envvars

Windows (PowerShell):

./dev-tools/setup_dev_envvars.ps1

UNIX (UNIX Shell):

source ./dev-tools/setup_dev_envvars.sh

3. Install dependencies

yarn install

Run & Debug

Run the project directly

yarn run dev

Debug in VSCode or Emacs (dap-mode)

electron-vite-react-debug.gif

Debug in other editors

Windows:

node_modules\.bin\electron --remote-debugging-port=9229 .

UNIX:

node_modules/.bin/electron --remote-debugging-port=9229 .

Then attach your debugger to port 9229.

Directory

  ├─┬ electron        == code that run in electron main thread.
  │ ├─┬ main
  │ │ └── index.ts    entry of Electron-Main
  │ └─┬ preload
  │   └── index.ts    entry of Preload-Scripts
  ├─┬ src             == code that run in electron renderer thread.
  │ └── main.ts       entry of Electron-Renderer
  ├── index.html
  ├── package.json
  └── vite.config.ts

FAQ