You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm encountering the following error while using react-datetime: Module not found: Error: Can't resolve 'moment' in 'node_modules/react-datetime/dist'
However, I don't want to install moment in my project. Is there a way to use react-datetime without needing moment as a dependency?
Could you provide guidance on how to resolve this issue or suggest alternatives to avoid installing moment?
Thanks in advance!
The text was updated successfully, but these errors were encountered:
@diennn-gg You see the error since the package requires moment as a peer dependency, which you don't want to install. I guess you can make a fork and replace moment with dayjs or any other library of your choice. However, some additional effort might be required to support timezones etc.
I'm encountering the following error while using react-datetime:
Module not found: Error: Can't resolve 'moment' in 'node_modules/react-datetime/dist'
However, I don't want to install moment in my project. Is there a way to use react-datetime without needing moment as a dependency?
Could you provide guidance on how to resolve this issue or suggest alternatives to avoid installing moment?
Thanks in advance!
The text was updated successfully, but these errors were encountered: