Drupal 9 module squeleton

Info file

In /modules/k4.info.yml
name: k4
description: k4 module.
package: AAA
type: module
core_version_requirement: ^8 || ^9

Routing file

In /modules/k4.routing.yml
k4.listprojects:
  path: '/k4/list_projects'
  defaults:
    _controller: '\Drupal\k4\Controller\k4ListProjectController::app'
    _title: ''
  requirements:
    _permission: 'access content'

libraries file

In /modules/k4.libraries.yml
Subscribe to codekarim.com RSS