Druxt.js - The Drupal powered Nuxt framework.
Druxt.js connects your Drupal backend to your Nuxt.js frontend through the power of Drupal's JSON API.
Features
- Drupal path alias and redirect compatible router.
- Entity / Field render system powered by Drupal display modes.
- Block render system with support for regions and custom content blocks.
- Views and Views blocks.
- On-demand JSON API resource engine with Vuex.
- Breadrumbs, Menus, Search API and more.
Install
$ npm install druxt
Usage
Add module to nuxt.config.js
module.exports = {
modules: [
...
'druxt'
],
druxt: {
baseUrl: 'https://example.com'
}
}
Ensure you have activated the Nuxt Vuex store.
Options
Base Druxt options
These options are available to all Druxt modules.
Option | Type | Required | Default | Description |
---|
axios | object | No | {} | Axios instance settings. |
baseUrl | string | Yes | null | Base URL for the Drupal installation. |
endpoint | string | No | /jsonapi | JSON:API Endpoint of the Drupal installation. |