简体   繁体   中英

React JS convert function to class (data from another file)

I'm trying to convert reactjs functions to class. I already import the object from the store but it doesn't render even though I don't have any error. Could somebody help me? 比较两个文件

I think you have to use redux on class components to use products. Or you can get products from props sent by parent component. I hope it will work for you. Regards.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM