Answers for "get date millis rails"

0

get date millis rails

require 'date'
DateTime.now.strftime('%s') # "1384526946" (seconds)
DateTime.now.strftime('%Q') # "1384526946523" (milliseconds)
Posted by: Guest on June-04-2021

Browse Popular Code Answers by Language