Alex Dunmow b9e8fe4bf1 feat(wasmguest): HostServices() — per-instance CoreServices accessor
Block/template render funcs receive only ctx+content over the ABI, no
services. Load runs on a single pooled instance, so a DB-backed block on
any other pooled instance had a nil pool. HostServices() exposes the
CoreServices bound at _initialize on every instance (live db.* Pool +
capability stubs) so render funcs resolve their pool per-instance. Zero
value in native builds (Serve never called); callers nil-check Pool.

Enables the symposium wasm port (WO-WZ-012).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-03 21:35:16 +08:00
2026-06-18 16:46:53 +08:00
2026-06-18 16:46:53 +08:00

BlockNinja Plugin SDK

Types, interfaces, and utilities for building BlockNinja plugins.

Package Structure

Package Purpose
plugin/ PluginRegistration, CoreServices, RegisterFunc
blocks/ BlockMeta, BlockFunc, BlockRegistry interface, BlockContext
blocks/builtin/ Reusable block implementations (HTMLBlock)
templates/ TemplateRegistry interface
templates/bn/ Shared templ components (head, engagement, toolbar)
auth/ Claims types, context extractors
content/ Content access interface
settings/ Settings access interface
gating/ Access gating evaluation
crypto/ Encrypt/Decrypt interface
render/ Rich text rendering utilities
video/ Video embed URL parsing
ai/ AI tool registry interface and types
rbac/ Role type definition

Usage

import "git.dev.alexdunmow.com/ninja/core/plugin"
Description
No description provided
Readme 2 MiB
Languages
Go 83.5%
templ 15.5%
Makefile 1%