Bundle Developer

Build Selene bundles against the current manifest, layout, and runtime loading rules.

Bundle development in Selene starts with one assumption: the server, client, or both are already running. Your job is to provide a bundle directory that uses bundle.json and the expected runtime folders so Selene can load it correctly.

This section covers the bundle-facing foundation you need:

  • The manifest fields your bundle can define
  • The terms used for bundles, entrypoints, dependencies, and preloads
  • The practical prerequisites for testing bundles on server and client
  • The directory layout and loading rules used by both runtimes

What a bundle needs

Both runtimes load a bundle.json file from a bundle directory:

  • The server looks for bundles under bundles_path/<bundle-name>
  • The client resolves bundles from --bundle <name> <path> launch arguments

bundle.json supports these fields:

{
  "name": "example.bundle",
  "description": "Human-readable bundle description",
  "entrypoints": [
    "common/init.lua",
    "server/init.lua"
  ],
  "dependencies": [
    "base.bundle"
  ],
  "preloads": {
    "example.shared": "common/shared.lua"
  }
}

name is required. description, entrypoints, dependencies, and preloads are optional, but most real bundles will use at least entrypoints and often dependencies.

Section map

  1. Start with Terminology so the docs use one consistent bundle vocabulary.
  2. Check Prerequisites before you connect a bundle to a running server or client.
  3. Use Bundle Layout when you scaffold a bundle or wire it into the server or client.