File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ Awesome Flutter Snippets is a collection of commonly used Flutter classes and me
33
33
| ` mounted ` | Mounted | Whether this State object is currently in a tree. |
34
34
| ` snk ` | Sink | A Sink is the input of a stream. |
35
35
| ` strm ` | Stream | A source of asynchronous data events. A stream can be of any data type. |
36
+ | ` subj ` | Subject | A BehaviorSubject is also a broadcast StreamController which returns an Observable rather than a Stream. |
36
37
| ` toStr ` | To String | Returns a string representation of this object. |
37
38
| ` debugP ` | Debug Print | Prints a message to the console, which you can access using the flutter tool's ` logs ` command (flutter logs). |
38
39
| ` importM ` | Material Package | Import Material package.
Original file line number Diff line number Diff line change 297
297
],
298
298
"description" : " A source of asynchronous data events. A stream can be of any data type <T>"
299
299
},
300
+ "Subject" : {
301
+ "prefix" : " subj" ,
302
+ "body" : [
303
+ " Stream<${1:type}> get ${2:name} => _${2:name}Subject.stream;" ,
304
+ " final _${2:name}Subject = BehaviorSubject<${1:type}>();"
305
+ ],
306
+ "description" : " A BehaviorSubject is also a broadcast StreamController which returns an Observable rather than a Stream."
307
+ },
300
308
"toString" : {
301
309
"prefix" : " toStr" ,
302
310
"body" : [
380
388
" }"
381
389
]
382
390
}
383
- }
391
+ }
You can’t perform that action at this time.
0 commit comments