Skip to content

Commit 91684d0

Browse files
committed
update README
1 parent cef698b commit 91684d0

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

README.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ This **completely bonkers** string will calculate _just_ the `x` position of a t
1414
This package allows you to build these string in a fluent way that's easily maintainable in a way that feels familiar to php and Laravel devs. The following example will output the exact same string as above, but imagine how much easier it'll be to change:
1515
```php
1616
$finalXpos = '(w*7/8)-text_w';
17-
$posX = (new Tween)
17+
$x = (new Tween())
1818
->from("{$finalXpos}-200")
1919
->to($finalXpos)
2020
->delay(Timing::seconds(5))
@@ -41,8 +41,16 @@ For now this package can only be used within a Laravel app, but there are plans
4141
## Usage
4242

4343
```php
44-
$fFMpegTween = new ProjektGopher\FFMpegTween();
45-
echo $fFMpegTween->echoPhrase('Hello, ProjektGopher!');
44+
use ProjektGopher\FFMpegTween\Tween;
45+
use ProjektGopher\FFMpegTween\Timing;
46+
use ProjektGopher\FFMpegTween\Enums\Ease;
47+
48+
$x = (new Tween())
49+
->from("50")
50+
->to("100")
51+
->delay(Timing::seconds(1))
52+
->duration(Timing::milliseconds(300))
53+
->ease(Ease::OutSine);
4654
```
4755

4856
## Testing

0 commit comments

Comments
 (0)