Skip to content
This repository was archived by the owner on Dec 14, 2019. It is now read-only.

Commit ba94ff3

Browse files
authored
Added tip about using shortcut methods to create factory models.
1 parent 36e3b76 commit ba94ff3

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

README.md

+15-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ Tinx calculates shortcut names via the implementation defined by your `strategy`
8585

8686
Lets say you have two models: `Car` and `Crocodile`.
8787

88-
If your naming `strategy` was set to **pascal** (default), Tinx would define the following shortcuts in your session:
88+
If your naming `strategy` was set to `pascal` (default), Tinx would define the following shortcuts in your session:
8989

9090
- Car: `$c`, `$c_`, `c()`
9191
- Crocodile: `$cr`, `$cr_`, `cr()`
@@ -108,6 +108,20 @@ To filter the shortcuts returned by `names()`, simply pass your filter terms lik
108108
names('car', 'user')
109109
```
110110

111+
### Fast factories
112+
113+
Shortcut methods are a great way to create factory models fast.
114+
115+
```php
116+
// Instead of this…
117+
factory(App\User::class)->create()
118+
119+
// …try substituting a shortcut method, like this:
120+
factory(u())->create()
121+
```
122+
123+
When tinkering, every keystroke counts!
124+
111125
## Configuration
112126

113127
Tinx contains a number of helpful configuration options.

0 commit comments

Comments
 (0)