Skip to content

Commit

Permalink
Merge tag 'v0.1.1' into develop
Browse files Browse the repository at this point in the history
* Added object type dictionary
  • Loading branch information
betterthanclay committed Nov 10, 2023
2 parents e9d839a + edc6980 commit 7e35852
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
## v0.1.1 (2023-11-10)
* Added object type dictionary

## v0.1.0 (2023-11-10)
Expand Down
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,17 @@ $testObect = $slingshot->instantiate(Test::class, [
]);
```

Objects can be added to Slingshot by type for reference matching:

```php
$object = new Test(...);
$slingshot->addType($object);

$slingshot->invoke(function(Test $test) {
// ...
});
```

## Licensing

Slingshot is licensed under the MIT License. See [LICENSE](./LICENSE) for the full license text.

0 comments on commit 7e35852

Please sign in to comment.