Check out example codes for "r convert date as timestamp". It will help you in understanding the concepts better.

Code Example 1

as.numeric(as.POSIXct("20/10/2020", format="%d/%m/%Y"))

Learn ReactJs, React Native from akashmittal.com