date-io icon indicating copy to clipboard operation
date-io copied to clipboard

Module not found: Can't resolve 'date-fns-jalali/addSeconds'

Open amirtahmouresi opened this issue 3 years ago • 1 comments

I intended to use material ui jalali date picker in react, so based on documentation I installed @date-io/date-fns-jalali library but my app had compile errors like "Module not found: Can't resolve 'date-fns-jalali/addSeconds'". After spending a lot of time to fix the error I found the solution. When you install date-fns-jalali library using npm i @date-io/date-fns-jalali command, you need also install date-fns-jalali modules using npm install date-fns-jalali command. If the error is not resolved, you may also need install date-fns library and it's modules using npm i @date-io/date-fns date-fns command. good luck👍

amirtahmouresi avatar Jul 06 '22 16:07 amirtahmouresi

I intended to use material ui jalali date picker in react, so based on documentation I installed @date-io/date-fns-jalali library but my app had compile errors like "Module not found: Can't resolve 'date-fns-jalali/addSeconds'". After spending a lot of time to fix the error I found the solution.

Could you link me the documentation you based your initial installation on ? If it was the MUI documentation and it was not clear, we have to improve it.

flaviendelangle avatar Sep 13 '22 06:09 flaviendelangle

I intended to use material ui jalali date picker in react, so based on documentation I installed @date-io/date-fns-jalali library but my app had compile errors like "Module not found: Can't resolve 'date-fns-jalali/addSeconds'". After spending a lot of time to fix the error I found the solution.

Could you link me the documentation you based your initial installation on ? If it was the MUI documentation and it was not clear, we have to improve it.

https://mui.com/x/react-date-pickers/date-picker/

amirtahmouresi avatar Nov 16 '22 08:11 amirtahmouresi