Nane
Nane

Reputation: 423

Cannot read property 'type' of undefined create-react-app build

I am trying to build by create-react-app project but I am getting this error I don't understand it is working properly in development "react-scripts": "3.1.1",

   Creating an optimized production build...
Failed to compile.

Cannot read property 'type' of undefined


npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] build: `react-scripts build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:

after a little bit googling I found this issue related to thunk

https://github.com/reduxjs/redux-thunk/issues/29

and my thunk code look like this

const axiosInstance = axios.create({
    baseURL:CONFIG.HOST,
    withCredentials: true
});



const store = createStore(reducers,  applyMiddleware(reduxThunk.withExtraArgument(axiosInstance)));

But i couldn't figure out what is happening

Upvotes: 0

Views: 1059

Answers (1)

Nane
Nane

Reputation: 423

After lot of debugging, I found I made a mistake while writing my scss code

changed from // syntactically wrong scss

transform: rotate3d(1deg);

to

transform: rotate3d(0,0,0,1deg);

this simple mistake causing the whole build fail

Upvotes: 2

Related Questions