Skip to content

Commit f082691

Browse files
authored
Update README.md
1 parent d824949 commit f082691

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

README.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,23 @@ You can manipaulate with state as you want. In addition you can also provide to
2222

2323
By default all changes are tracked by a shared instance of **BlocObserver** and currently only make console printing. You can always set a custom observer for the shared instance and override open methods as you wish.
2424

25+
For convinience you can use a ruby script *bloc_template.rb*. You need to provide additional parameters for executing the script.
26+
- path
27+
- class_name
28+
- type
29+
30+
Example:
31+
32+
```ruby
33+
# creates a cubit
34+
ruby bloc_template /MY_PROJECT/MY_CUBIT_FOLDER Counter cubit
35+
```
36+
37+
```ruby
38+
# creates a bloc
39+
ruby bloc_template /MY_PROJECT/MY_CUBIT_FOLDER Counter bloc
40+
```
41+
2542
### Cubit
2643

2744
If you go with **Cubit** first you need to create a child class. The generic type **State** can be any type which conforms **Equitable** protocol.

0 commit comments

Comments
 (0)