1
1
mirror of https://github.com/jxnblk/mdx-deck.git synced 2024-09-11 06:35:24 +03:00

Using constant for normal mode on step 0

This commit is contained in:
Pedro Filho 2020-01-26 13:18:59 +00:00
parent b1b7062859
commit d54100e129

View File

@ -1,6 +1,7 @@
import React, { useReducer } from 'react'
import merge from 'lodash.merge'
import Context from '../context'
import { modes } from '../constants'
const reducer = (state, next) =>
typeof next === 'function'
@ -9,7 +10,7 @@ const reducer = (state, next) =>
export default props => {
const [state, setState] = useReducer(reducer, {
mode: 'normal',
mode: modes.normal,
step: 0,
metadata: {},
})