Documentation
¶
Index ¶
- func APIKey(relative string) string
- func BuildID(root string, routes []Route) (string, error)
- func BuildSnapshot(root string) (map[string]string, error)
- func Generate(root, buildRoot string, check bool) error
- func SyncGoSources(root string, routes []Route, check bool) error
- func Write(root string, routes []Route, buildID string, check bool) error
- type Manifest
- type Route
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func APIKey ¶
APIKey returns the deterministic, Go-safe generated package directory for a co-located app/api route. The input is relative to app/api.
func BuildSnapshot ¶
BuildSnapshot records the same source files used by BuildID, keyed by their slash-normalized path relative to root. Development mode uses it to identify which build products a source edit can affect.
func SyncGoSources ¶
SyncGoSources projects route-owned Go into import-safe generated packages. Authored app directories remain editor inputs and are never imported by the production server.
Types ¶
type Manifest ¶
type Manifest struct {
APIVersion string `json:"apiVersion"`
BuildID string `json:"buildId"`
Routes []Route `json:"routes"`
}
func LoadManifest ¶
type Route ¶
type Route struct {
ID string `json:"id"`
Pattern string `json:"pattern"`
Mode string `json:"mode"`
Reason string `json:"reason"`
AppDir string `json:"appDir"`
ServerKey string `json:"serverKey"`
PageFile string `json:"pageFile"`
SchemaFile string `json:"schemaFile,omitempty"`
BuildFile string `json:"buildFile,omitempty"`
ServerFile string `json:"serverFile,omitempty"`
PlanFile string `json:"planFile"`
ClientEntry string `json:"clientEntry"`
}
Click to show internal directories.
Click to hide internal directories.