Skip to content

Commit

Permalink
add-api-proxy: Add back README commit
Browse files Browse the repository at this point in the history
  • Loading branch information
vloss3 committed Dec 6, 2023
1 parent da133ce commit f454685
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,14 +60,13 @@ rm -f app.vue && npx nuxt-drupal-ce-init
* Provides unstyled skeleton components for getting started quickly.
* Supports fetching and display of Drupal menus via the [Rest menu items](https://www.drupal.org/project/rest_menu_items) module.


## Options

- `baseURL`: The Drupal base URL. Defaults to the `DRUPAL_BASE_URL`
- `drupalBaseUrl`: The Drupal base URL. Defaults to the `DRUPAL_BASE_URL`
environment variable if provided, otherwise to `http://localhost:8888`.

- `drupalBaseUrl`: The Drupal origin. Defaults to parsing the origin from `baseURL` if unset.

- `serverDrupalBaseUrl`: The Node.js server base URL(optional).
- `serverDrupalBaseUrl`: Optionally, an alternative drupal base URL to apply in server context.

- `ceApiEndpoint`: The custom elements API endpoint. Defaults to `/ce-api`.

Expand All @@ -94,6 +93,14 @@ is added automatically to requests. Defaults to `false`.

- `useLocalizedMenuEndpoint`: If enabled, the menu endpoint will use a language prefix as configured by [nuxtjs/i18n](https://v8.i18n.nuxtjs.org) module. Defaults to `true`.

## Deprecated options

The following options are deprecated and only there for improved backwards compatibility.

- `baseURL`: The base URL of the Drupal /ce-api endpoint, e.g. http://localhost:8888/ce-api.
If set, `drupalBaseUrl` is set with the origin of the provided URL.


## Error handling

The module provides a default error handler for the `fetchPage` and `fetchMenu` methods:
Expand Down

0 comments on commit f454685

Please sign in to comment.