docs: added dividers + see also section (#2899)
This commit is contained in:
@@ -23,6 +23,8 @@ class HelloService extends TransactionBaseService {
|
||||
export default HelloService
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Service Constructor
|
||||
|
||||
As the service extends the `TransactionBaseService` class, all services in Medusa’s core, as well as all your custom services, will be available in your service’s constructor using dependency injection.
|
||||
@@ -46,6 +48,8 @@ async getProductCount() {
|
||||
}
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Use a Service
|
||||
|
||||
In this section, you'll learn how to use services throughout your Medusa server. This includes both Medusa's services and your custom services.
|
||||
@@ -93,7 +97,9 @@ constructor({ helloService, eventBusService }) {
|
||||
}
|
||||
```
|
||||
|
||||
## What’s Next
|
||||
---
|
||||
|
||||
- Check out the [Services Reference](/references/services/classes/AuthService) to see a list of all services in Medusa.
|
||||
- [Learn How to Create an Endpoint.](../endpoints/add.md)
|
||||
## See Also
|
||||
|
||||
- [Services Reference](/references/services/classes/AuthService)
|
||||
- [Create an Endpoint](../endpoints/add.md)
|
||||
|
||||
@@ -18,7 +18,9 @@ For example, if the file name is `hello.ts`, the service will be registered as `
|
||||
|
||||
The registration name of the service is important, as you’ll be referring to it when you want to get access to the service using dependency injection or in routes.
|
||||
|
||||
## What's Next
|
||||
---
|
||||
|
||||
- Learn [how to create a service](./create-service.md)
|
||||
- Check out the [Services Reference](/references/services/classes/AuthService) to see a list of all services in Medusa.
|
||||
## See Also
|
||||
|
||||
- [Create a Service](./create-service.md)
|
||||
- [Services Reference](/references/services/classes/AuthService)
|
||||
|
||||
Reference in New Issue
Block a user