chore(template): clean-slate template snapshot from bb4a0c7
Curated, product-agnostic snapshot of the post-story-04 tree: demo content deleted, auth-only reference feature, web-next shell, all gates green. Product-specific docs, ADRs 027-029, PRDs/epics/archive, editor library traces, and product naming are curated out; generic template repairs (coverage provider devDeps, root test:coverage script, live lint fixes, root-only release-please) are kept. See TEMPLATE.md for provenance, curation list, and usage. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016j8z4VHjedXDTjEDNg7qHK
This commit is contained in:
14
turbo/generators/templates/event/consume/handler.ts.hbs
Normal file
14
turbo/generators/templates/event/consume/handler.ts.hbs
Normal file
@@ -0,0 +1,14 @@
|
||||
// packages/{{kebabCase feature}}/src/events/handlers/on-{{kebabCase publisher}}-{{kebabCase event}}.handler.ts
|
||||
import type { {{pascalCase event}}Event } from "@repo/{{kebabCase publisher}}";
|
||||
|
||||
export type IOn{{pascalCase publisher}}{{pascalCase event}}Handler = ReturnType<
|
||||
typeof on{{pascalCase publisher}}{{pascalCase event}}Handler
|
||||
>;
|
||||
|
||||
export const on{{pascalCase publisher}}{{pascalCase event}}Handler =
|
||||
() =>
|
||||
async (_event: {{pascalCase event}}Event): Promise<void> => {
|
||||
// TODO: implement the reaction. Inject dependencies via the factory's
|
||||
// constructor and use them here. The handler runs inside the consumer's
|
||||
// span+capture sandwich, so just throwing on failure is the right shape.
|
||||
};
|
||||
Reference in New Issue
Block a user