App Directory
Addfox follows a convention-over-configuration design philosophy. Understanding the standard directory structure helps you get started quickly and follow best practices.
Project Root
A typical Addfox project structure looks like this:
.addfox Directory
.addfox is auto-generated by the framework and contains:
extension/— Default build output directory (can be changed viaoutDir)cache/— Build cache for accelerating subsequent builds
Avoid deleting the cache directory unless necessary, as it affects build speed and browser user data reuse.
app Directory
app/ is the default application source directory, containing all extension entries and manifest files. You can change it via the appDir config option:
Recommended Directory Structure
For more about entry discovery rules, see File-based Entry and entry config.
public Directory
public/ is for static assets, which are copied as-is to the output directory during build without processing:
When referencing these resources in code, use paths relative to the output root:
Entry Types
Addfox supports the following built-in entries:
Built-in entry names cannot be changed, as Addfox relies on them for automatic recognition.
Configuration Files
addfox.config.ts / addfox.config.js
This is the required configuration file for Addfox, used to declare:
- Extension manifest
- Entry files
- Output directory
- Rsbuild plugins and configuration

