Project Liberty code application skeleton: application

v1.0.1 2024-08-17 18:00 UTC

This package is auto-updated.

Last update: 2025-02-17 19:02:50 UTC


README

Description

LibertyCode application skeleton application contains main components, to create and run basic application.

Requirement

  • Script language: PHP: version 7 || 8

Installation

  1. Requirement

  2. Command: Installation

    Several ways are possible:

  3. Command: Move in project root directory

     cd "<project_root_dir_path>"
    
  4. Command: External libraries installation

    Required only if not installed via composer.

     php composer.phar install
    
  5. Note

    • External libraries installation

      All external libraries are listed on composer file "

      Instruction are set for composer. It's possible to use any way, while all external libraries, listed on composer configuration, are installed and correctly configured, on module configuration file "

Application structure

Configuration [compulsory]

Configuration directory contains all application configuration. PHP format is used. It's possible to set other available format (JSON, XML, YML, ...), in application bootstrap.

Elements

  • Application mode file

    Stores application modes available.

  • Module file

    Registers modules available in application.

Source [suggested]

Source directory contains all application source code, structured by modules.

Resource [suggested]

Resource directory contains all application front resources, like views, assets, ....

Bin [suggested]

Bin directory contains command line application and other command line executables.

Elements

  • Application file

    Application bootstrap for command line.

Web [suggested]

Web directory contains web application and other web accessible components.

Elements

  • Index file

    Application bootstrap for web.

Variable [suggested/compulsory, generated]

Variable directory contains all temporary and/or flexible components, generated by application.

Elements

  • Cache directories

    Used by caches for application, framework, view ...

  • Log directory

    Store logs.

Module structure

Module configuration [compulsory]

Module file contains module macro information.

Configuration [compulsory]

Configuration directory contains module configuration. By default the application configuration format is used. You can set other available format (JSON, XML, PHP, ...), in application configuration module file.

Elements

  • Parameters file ("

    Stores module parameters, available in module.

  • Application parameters file ("

    Stores application parameters, available in application.

  • Auto-loading file ("

    Stores module auto-loading rules, available in application.

  • Dependency injection file ("

    Stores module dependencies, available in application.

  • Register file ("

    Stores module key-value pairs, available in application.

  • Events file ("

    Stores module event, available in application.

  • HTTP routes file ("

    Stores module web routes, available in application.

  • Command line routes file ("

    Stores module command line routes, available in application.

  • Boot file ("

    Stores module bootstrap files, available in application.