docs: integrate Vale for documentation linting (#2242)
* added value rules * resolved errors raised by vale * added github action * fixes to github action * added details in contribution guidelines * added rule for numbers * limited checks to errors
This commit is contained in:
1 parent
d0d789b6d4
commit
6adaf56c73
103 files changed
+2408
-832
No files matched your search
@@ -100,7 +100,7 @@ When an event is triggered that your Notification Provider is registered as a ha
|
||||
|
||||
In this method, you can perform the necessary operation to send the Notification. Following the example above, you can send an email to the customer when they place an order.
|
||||
|
||||
This method receives 3 parameters:
|
||||
This method receives three parameters:
|
||||
|
||||
1. `eventName`: This is the name of the event that was triggered. For example, `order.placed`.
|
||||
2. `eventData`: This is the data payload of the event that was triggered. For example, if the `order.placed` event is triggered, the `eventData` object contains the property `id` which is the ID of the order that was placed.
|
||||
@@ -156,7 +156,7 @@ The `to` and `data` properties are used in the `NotificationService` in Medusa
|
||||
|
||||
Using the [Resend Notification endpoint](https://docs.medusajs.com/api/admin/#tag/Notification/operation/PostNotificationsNotificationResend), an admin user can resend a Notification to the customer. The [`NotificationService`](../../../references/services/classes/NotificationService.md) in Medusa’s core then executes the `resendNotification` method in your Notification Provider.
|
||||
|
||||
This method receives 3 parameters:
|
||||
This method receives three parameters:
|
||||
|
||||
1. `notification`: This is the original Notification record that was created after you sent the notification with `sendNotification`. You can get an overview of the entity and its attributes in the [architecture overview](overview.md#notification-entity-overview), but most notably it includes the `to` and `data` attributes which are populated originally using the `to` and `data` properties of the object you return in `sendNotification`.
|
||||
2. `config`: In the Resend Notification endpoint you may specify an alternative receiver of the notification using the `to` request body parameter. For example, you may want to resend the order confirmation email to a different email. If that’s the case, you have access to it in the `config` parameter object. Otherwise, `config` will be an empty object.
|
||||
@@ -240,7 +240,7 @@ Then, place an order either using the [REST APIs](https://docs.medusajs.com/api/
|
||||
|
||||
:::tip
|
||||
|
||||
If you don’t have a storefront installed you can get started with either our [Next.js](../../../starters/nextjs-medusa-starter.md) or [Gatsby](../../../starters/gatsby-medusa-starter.md) starter storefronts in minutes.
|
||||
If you don’t have a storefront installed you can get started with either the [Next.js](../../../starters/nextjs-medusa-starter.md) or [Gatsby](../../../starters/gatsby-medusa-starter.md) starter storefronts in minutes.
|
||||
|
||||
:::
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ This document gives an overview of the notification architecture and how it work
|
||||
|
||||
Medusa provides a Notification API to mainly handle sending and resending notifications when an event occurs. For example, sending an email to the customer when they place an order.
|
||||
|
||||
The Notification architecture is made up of 2 main components: the Notification Provider and the Notification. Simply put, the Notification Provider handles the sending and resending of a Notification.
|
||||
The Notification architecture is made up of two main components: the Notification Provider and the Notification. Simply put, the Notification Provider handles the sending and resending of a Notification.
|
||||
|
||||
## Notification Provider
|
||||
|
||||
@@ -48,7 +48,7 @@ A Notification also represents a resent notification. So, when a notification is
|
||||
|
||||
### Notification Entity Overview
|
||||
|
||||
The 2 most important properties in the `Notification` entity are the `to` and `data` properties.
|
||||
The two most important properties in the `Notification` entity are the `to` and `data` properties.
|
||||
|
||||
The `to` property is a string that represents the receiver of the Notification. For example, if the Notification was sent to an email address, the `to` property holds the email address the Notification was sent to.
|
||||
|
||||
|
||||
Reference in new issue
Block a user