Skip to content

Commit 4b0e821

Browse files
Samuel  TranSamuel  Tran
authored andcommitted
Changed import split from react-split module to require
dquote> dquote> Changing import split to require from react-split module allows TS compatibility because it change the type of Steps to any which is what was the problem before. Left comments inside to aid next iterator to fix this er ror if possible
1 parent 8744a5e commit 4b0e821

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/app/containers/MainContainer.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
/* eslint-disable max-len */
2-
// @ts-nocheck
32
import React, { useEffect, useState } from 'react';
4-
import Split from 'react-split';
53
import ActionContainer from './ActionContainer';
64
import TravelContainer from './TravelContainer';
75
import ButtonsContainer from './ButtonsContainer';
@@ -19,6 +17,9 @@ import {
1917
} from '../actions/actions';
2018
import { useStoreContext } from '../store';
2119

20+
//Must be required in. This enables compatibility with TS. If imported in, throws ts error of not rendering steps as a class component correctly.
21+
const Split = require('react-split');
22+
2223
function MainContainer(): JSX.Element {
2324
const [store, dispatch] = useStoreContext();
2425
const {

0 commit comments

Comments
 (0)