docs: updated Docusaurus + fix recurring error (#1244)
This commit is contained in:
@@ -36,7 +36,11 @@ This exports a function that returns an Express router. In that function, you ca
|
||||
|
||||
Now, if you run your server and send a request to `/admin/hello`, you will receive a JSON response message.
|
||||
|
||||
> Custom endpoints are compiled into the `dist` directory of your Backend when you run your server using `medusa develop`, while it’s running, and when you run `npm run build`.
|
||||
:::note
|
||||
|
||||
Custom endpoints are compiled into the `dist` directory of your Backend when you run your server using `medusa develop`, while it’s running, and when you run `npm run build`.
|
||||
|
||||
:::
|
||||
|
||||
## Accessing Endpoints from Admin
|
||||
|
||||
|
||||
@@ -36,7 +36,11 @@ This exports a function that returns an Express router. In that function, you ca
|
||||
|
||||
Now, if you run your server and send a request to `/store/hello`, you will receive a JSON response message.
|
||||
|
||||
> Custom endpoints are compiled into the `dist` directory of your Backend when you run your server using `medusa develop`, while it’s running, and when you run `npm run build`.
|
||||
:::note
|
||||
|
||||
Custom endpoints are compiled into the `dist` directory of your Backend when you run your server using `medusa develop`, while it’s running, and when you run `npm run build`.
|
||||
|
||||
:::
|
||||
|
||||
## Multiple Endpoints
|
||||
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
# Documentation Error
|
||||
|
||||
If you have installed the dependencies in the root of this repository (i.e., if you have a `node_modules` directory at the root of this repository), this will cause an error when running this documentation website. This is because the content resides in `docs/content` and when that content is being imported from there, a mix up can happen between the dependencies which will cause an `invalid hook call` error.
|
||||
|
||||
For that reason, we added a `clean-node-modules` script that deletes the `node_modules` directory, and we call that script before the `start` and `build` scripts are ran.
|
||||
|
||||
So, everytime you run these 2 scripts, the `node_modules` directory at the root will be deleted.
|
||||
Reference in New Issue
Block a user