Skip to content

Instantly share code, notes, and snippets.

View pesakitan22's full-sized avatar
🍜
pengen tuku mie ayam tapi randue duit

Deni Putra pesakitan22

🍜
pengen tuku mie ayam tapi randue duit
View GitHub Profile
@pesakitan22
pesakitan22 / CategorySagas.js
Last active February 19, 2021 18:45
Redux-Saga for next.js
import {call, put, take, fork} from 'redux-saga/effects'
import {END} from 'redux-saga'
import CategoryActions, {CategoryTypes} from '../Redux/CategoryRedux'
// attempts to fetch category
export function* fetchCategoryServer (api) {
let action = yield take(CategoryTypes.CATEGORY_SERVER)
// check when it stopped
while (action !== END) {
yield fork(fetchCategoryAPI, api)

Keybase proof

I hereby claim:

  • I am pesakitan22 on github.
  • I am vixtorious (https://keybase.io/vixtorious) on keybase.
  • I have a public key ASBjRXT0erZSnGad0vYEdTbPEL6D9FGfbLuPxpetORUYZwo

To claim this, I am signing this object: