Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jongotlin/danishdatesbundle
https://github.com/jongotlin/danishdatesbundle
Last synced: 15 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/jongotlin/danishdatesbundle
- Owner: jongotlin
- License: mit
- Created: 2018-09-28T17:52:03.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2022-09-02T19:54:59.000Z (over 2 years ago)
- Last Synced: 2024-12-04T08:05:47.642Z (about 1 month ago)
- Language: PHP
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
DanishDatesBundle
==================## Installation
Install with composer
```
$ composer require jongotlin/danish-dates-bundle
```Add the bundle to your AppKernel.
```php
new JGI\DanishDatesBundle\JGIDanishDatesBundle(),
```## Usage
```php
$date = $container->get('jgi.danish_dates.datemanager')->getDate(new \Datetime('2018-01-01'));
echo $date->getDateTime()->format('Y-m-d') . ": " .
($date->isRedDay() ? 'red day' : 'not red day') . ' - ' . $date->getName();
// 2018-01-01: red day - Nytårsdag
```## License
Bundle under the MIT License