@stringke/sigi-react-router
v2.11.3-alpha.1
Published
React router integration for sigi framework
Downloads
2
Readme
@stringke/sigi-react-router
React router integration for sigi framework
Usage
import { RouterModule } from '@stringke/sigi-react-router'
@Module('App')
export class AppModule extends EffectModule<{}> {
constructor(private readonly router: RouterModule) {
super()
}
@Effect()
getUser(payload$: Observable<void>) {
return payload$.pipe(
exhaustMap(() => {
service.getUser().pipe(mergeMap((res) => of(this.getActions().getUserResponse(res), this.router.push('/home'))))
}),
)
}
}