PostComponentBloc constructor
PostComponentBloc({
- PostRepository? postRepository,
Implementation
PostComponentBloc({this.postRepository})
: super(PostComponentUninitialized()) {
on<FetchPostComponent>((event, emit) {
_mapLoadPostComponentUpdateToState(event.id!);
});
on<PostComponentUpdated>((event, emit) {
emit(PostComponentLoaded(value: event.value));
});
}