import { store } from 'app/store' export const getSection = index => { const { sections } = store.getState().viewer return sections[index] } export const getNextSection = section => { const { sections } = store.getState().viewer if (section.index === sections.length - 1) { return null } return sections[section.index + 1] }