<commit_before># Dynamic dependency injection

This is a small PHP code that demonstrates injecting a dependency that is not known until runtime.

Reading the comments in the code will hopefully explain the idea clearly.

To try it / play with it:

`$ git clone https://github.com/pwm/dynamic-dependency-injection.git`

`$ composer install`

`$ app/console feed-reader json "http://foobar.com/feed"`
 
Open for any suggestions/improvements.
<commit_msg>Update readme with explanation link<commit_after># Dynamic dependency injection

Sample PHP code that demonstrates injecting a dependency that is not known until runtime.

[Click here for explanation](http://pwm.github.io/dynamic-dependency-injection/)

To try it / play with it:

`$ git clone https://github.com/pwm/dynamic-dependency-injection.git`

`$ cd dynamic-dependency-injection`

`$ composer install`

`$ app/console feed-reader json "http://foobar.com/feed"`
 
Open for suggestions/improvements.

{'fraction_non_alphanumeric': 0.0948905109489051, 'fraction_numerical': 0.0, 'mean_word_length': 4.5813953488372094, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6900768', 'n_tokens_mistral': 282, 'n_tokens_neox': 258, 'n_words': 98}