docs: update events reference (#7321)

* change subscribers events

* add event references for modules
This commit is contained in:
Shahed Nasser authored and GitHub committed 2024-05-16 09:01:12 +02:00
1 parent 1160a34f3d
commit 9b1998b9b2
44 files changed
+2995 -3280

No files matched your search

@@ -21,7 +21,6 @@ export const highlights = [
```ts title="src/subscribers/product-created.ts" highlights={highlights}
import {
ProductService,
SubscriberArgs,
type SubscriberConfig,
} from "@medusajs/medusa"
@@ -33,11 +32,11 @@ export default async function productCreateHandler({
}
export const config: SubscriberConfig = {
event: ProductService.Events.CREATED,
event: "product.created",
}
```
This logs the product ID received in the `ProductService.Events.CREATED` (`product-created`) event’s data payload to the console.
This logs the product ID received in the `product.created` event’s data payload to the console.
## List of Events with Data Payload