2017 © Pedro Peláez
 

library dirs

Easier access to individual directories in an application.

image

drago-ex/dirs

Easier access to individual directories in an application.

  • Wednesday, May 30, 2018
  • by accgit
  • Repository
  • 1 Watchers
  • 0 Stars
  • 200 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 7 Versions
  • 24 % Grown

The README.md

Drago Parameters

A lightweight extension for managing application directory paths (such as application, public, and temporary directories) within a Nette-based project. Provides a simple way to access these paths via dependency injection., (*1)

License: MIT PHP version Tests Coding Style CodeFactor Coverage Status, (*2)

Technology

  • PHP 8.3 or higher
  • composer

Installation

composer require drago-ex/parameters

Extension registration

To enable the Parameters extension in your Nette project, add the following configuration to your neon file. This registers the ParametersExtension and injects paths to the application, public, and temporary directories., (*3)

extensions:
    - Drago\Parameters\DI\ParametersExtension(appDir: %appDir%, wwwDir: %wwwDir%, tempDir: %tempDir%)

This will automatically inject the directory paths as services into your project., (*4)

Accessing Directories in Your Application

Once registered, you can access the directory paths throughout your application using the following properties:, (*5)

Application Directory

To get the path to your application's directory (usually the root directory of your app), use:, (*6)

$this->appDir;

Public Directory

To get the path to your public directory (e.g., the www or public directory):, (*7)

$this->wwwDir;

Temporary Directory

To get the path to the temporary directory (where cache or logs might be stored):, (*8)

$this->tempDir;

The Versions

30/05 2018

dev-master

9999999-dev

Easier access to individual directories in an application.

  Sources   Download

MIT

The Requires

 

30/05 2018

v1.0.1

1.0.1.0

Easier access to individual directories in an application.

  Sources   Download

MIT

The Requires

 

29/05 2018

v1.0.x-dev

1.0.9999999.9999999-dev

Easier access to individual directories in an application.

  Sources   Download

MIT

The Requires

 

29/05 2018

v2.0.x-dev

2.0.9999999.9999999-dev

Easier access to individual directories in an application.

  Sources   Download

MIT

The Requires

 

18/10 2017

v1.0.0

1.0.0.0

Easier access to individual directories in an application.

  Sources   Download

MIT

The Requires

 

09/08 2017

v1.0.3

1.0.3.0

Eeasier access to individual directories.

  Sources   Download

MIT

The Requires

 

23/07 2017

v1.0.2

1.0.2.0

Eeasier access to individual directories.

  Sources   Download

MIT

The Requires