Skip to content

Commit 1dbe717

Browse files
committed
Strings 2.4.0
1 parent 02a8bc3 commit 1dbe717

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

CHANGELOG.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,21 @@
1+
<a name="2.4.0"></a>
2+
# [2.4.0](https://github.com/atomastic/strings) (2020-12-05)
3+
* add copy() method.
4+
* add ability to extend Strings class with Macros.
5+
6+
```php
7+
use Atomastic\Strings\Strings;
8+
use Atomastic\Macroable\Macroable;
9+
10+
Strings::macro('concatenate', function(string $string) {
11+
return $this->toString() . $string;
12+
});
13+
14+
$strings = new Strings('Hello');
15+
16+
echo $strings->concatenate(' World'));
17+
```
18+
119
<a name="2.3.0"></a>
220
# [2.3.0](https://github.com/atomastic/strings) (2020-11-30)
321
* add replace() method.

0 commit comments

Comments
 (0)