Skip to content

Commit 90473fa

Browse files
committed
added aliases to hierarchy and viewIndex to try to fix webpack error. Not working yet, moving to dev to debug.
1 parent 902536b commit 90473fa

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/app/components/StateRoute/StateRoute.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@ const NO_STATE_MSG = 'No state change detected. Trigger an event to change state
2626
const StateRoute = (props: StateRouteProps) => {
2727
const {
2828
snapshot, // from 'tabs[currentTab]' object in 'MainContainer'
29-
hierarchy, // from 'tabs[currentTab]' object in 'MainContainer'
29+
propsHierarchy: hierarchy, // from 'tabs[currentTab]' object in 'MainContainer'
3030
snapshots, // from 'tabs[currentTab].snapshotDisplay' object in 'MainContainer'
31-
viewIndex, // from 'tabs[currentTab]' object in 'MainContainer'
31+
propsViewIndex: viewIndex, // from 'tabs[currentTab]' object in 'MainContainer'
3232
webMetrics, // from 'tabs[currentTab]' object in 'MainContainer'
3333
currLocation, // from 'tabs[currentTab]' object in 'MainContainer'
3434
} = props;
3535

3636
const { tabs, currentTab }: MainState = useSelector((state: RootState) => state.main);
37-
const { hierarchy, sliderIndex, viewIndex } = tabs[currentTab];
38-
// const hierarchy = propsHierarchy || tabsHierarchy; JR: RETURN TO THIS: alias to deconstruct from props and tab with the same name, aliases were deleted above
39-
// const viewIndex = propsViewIndex || tabsViewIndex;
37+
const { tabsHierarchy: hierarchy, sliderIndex, tabsViewIndex: viewIndex } = tabs[currentTab];
38+
const hierarchy = propsHierarchy || tabsHierarchy; // JR: RETURN TO THIS: alias to deconstruct from props and tab with the same name, aliases were deleted above
39+
const viewIndex = propsViewIndex || tabsViewIndex;
4040

4141
const renderComponentMap = () => {
4242
if (hierarchy) {

0 commit comments

Comments
 (0)