Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Multiexcerpt
MultiExcerptNamestructure-comparison
Magnolia module wrapped in a typical Maven module
structure before it is built.
File-based Magnolia module under $magnolia.resources.dir
=
Light module 
Code Block
<maven-module-name>/
    ├── pom.xml
    └── src/
        └── main/
            ├── java/
            └── resources/
                ├── META-INF/
                │   └── magnolia/
                │       └── module-name.xml
                └── <module-name>/
                    ├── apps/
                    ├── dialogs/
                    │   └── myDialog.yaml
                    ├── webresources/
                    └── templates/
                        ├── components/
                        │   ├── myComponent.ftl
                        │   └── myComponent.yaml
                        └── pages/
                            ├── myTemplate.ftl
                            └── myTemplate.yaml
Code Block
 
 

 
 
 
 

$magnolia.resources.dir/
└── <module-name>/
    ├── apps/
    ├── dialogs/
    │   └── myDialog.yaml
    ├── module.yaml
    ├── webresources/
    └── templates/
        ├── components/
        │   ├── myComponent.ftl
        │   └── myComponent.yaml
        └── pages/
            ├── myTemplate.ftl
            └── myTemplate.yaml



Notes:

  • Include Page
    _What is magnolia.resources.dir
    _What is magnolia.resources.dir
  • <module-name> folder contains exactly the same content in a Maven module and folder-based module. In a Maven module this folder is within src/main/resources . In a folder-based modules this folder is within $magnolia.resources.dir.
  • Include Page
    INCL:_module_name allowed characters
    INCL:_module_name allowed characters

...

By default $magnolia.resources.dir is the webapp folder, for instance magnoliaAuthor or magnoliaPublic. See Add the module folder to $magnolia.home for more information about $magnolia.home.

Creating a light module with Magnolia CLI

Include Page
_Creating a light module with Magnolia CLI
_Creating a light module with Magnolia CLI

Magnolia Maven module

If you are familiar with Java and Maven you may want to use Maven to create and build your Magnolia module. Using Maven eases the process of creating a JAR file, deployment, and dependency management of your modules. All modules provided by Magnolia are built with Maven. This makes it easy to install or uninstall them by adding or removing a JAR file. 

...