Kustomisasi Dasar¶
Setelah instalasi Drupal, maka ada beberapa hal yang perlu dikustomisasi agar website sesuai dengan yang diinginkan.
Install Theme¶
Yoopa menggunakan theme Bootstrap. Cara installnya:
Buka Command Prompt, lalu masuk ke folder website Yoopa/Drupal Anda, contoh:
C: cd \xampp\htdocs\lskk.org
Install module
drupal/bootstrap
menggunakan Composer:composer -vvv require drupal/bootstrap
Di website, klik Manage > Appearance. Akan muncul theme Bootstrap, klik Install and set as default.
Di Bootstrap > Settings, Anda dapat mengatur lebih jauh. Bootstrap sendiri mendukung Bootswatch yaitu “sub-theme” dari Bootstrap. Klik Advanced > Theme > pilih Bootswatch sub-theme pilihan Anda.
Pathauto¶
Dibutuhkan agar URI untuk masing-masing content bersifat SEO-friendly.
Install module
drupal/pathauto
menggunakan Composer:composer -vvv require drupal/pathauto
Di web, klik Manage > Extend
Centang Pathauto, klik Install.
Manage > Configuration > Development > Performance > Clear all caches
Manage > Configuration > Search and metadata > Bulk generate > Content
Realname¶
TODO: Menunggu kesiapan dari modul Realname untuk Drupal 8. Terutama, bug ini masih pending.
REST API¶
Install module drupal/restui menggunakan Composer:
composer -vvv require drupal/restui
Manage > Extend. Enable modules:
- HAL
- HTTP Basic Authentication
- REST UI
- RESTful Web Services
- Serialization
- Manage > People > Permissions. Set permissions:
- GET: Anonymous, Authenticated
- POST/PATCH/DELETE: Authenticated
- Manage > Configuration > REST.
Secara default, resource yang enabled adalah Content dengan formathal_json
. Pastikan hal ini benar.
- Test menggunakan browser atau Postman: http://lskk.org.amanahwin/node/1?_format=hal_json
Install Display Suite¶
Display Suite digunakan untuk mengatur layout content secara GUI di website Drupal, tanpa membuat template.
Require module drupal/ds menggunakan Composer:
composer -vvv require drupal/ds
Di web, klik Manage > Extend
Centang Display Suite dan Display Suite Extras, klik Install.