https://github.com/nette-examples/books
https://github.com/nette-examples/books
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/nette-examples/books
- Owner: nette-examples
- License: other
- Created: 2020-11-25T17:20:28.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-12-17T04:57:08.000Z (over 1 year ago)
- Last Synced: 2025-01-21T18:49:14.945Z (over 1 year ago)
- Size: 11.7 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license.md
Awesome Lists containing this project
README
Nette DI Container Example
==========================
This repository demonstrates the use of Nette's Dependency Injection (DI) Container.
What is Dependency Injection (DI)?
----------------------------------
Dependency Injection (DI) aims to decouple classes from the responsibility of obtaining the objects they require for their operation. Such required objects are referred to as **services**. For an in-depth understanding, refer to the official [Nette DI documentation](https://doc.nette.org/en/dependency-injection).
Installation
------------
Follow these steps to set up the example:
1. Clone the repository:
```shell
git clone https://github.com/nette-examples/books
```
2. Navigate to the project directory:
```shell
cd books
```
3. Install the required dependencies:
```shell
composer install
```
Running the Demo
----------------
Execute the demo using the following command:
```shell
php demo/demo.php
```
Requirements
------------
Ensure you have PHP version 7.2 or above installed to run the demo.