How do you convert a Date to a DateValue? #7804
-
| Given this is javascript, I am working with  How can you have a controlled date range picker? Or at least provide a default value? | 
Beta Was this translation helpful? Give feedback.
      
      
          Answered by
          
            devongovett
          
      
      
        Feb 20, 2025 
      
    
    Replies: 1 comment
-
| import {fromDate} from "@internationalized/date";
fromDate(someDate, timeZone)https://react-spectrum.adobe.com/internationalized/date/ZonedDateTime.html | 
Beta Was this translation helpful? Give feedback.
                  
                    0 replies
                  
                
            
      Answer selected by
        cmmartin
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
https://react-spectrum.adobe.com/internationalized/date/ZonedDateTime.html