i have used daylight time saving check in php using below code
if (date('I', time()))
{
$time_zone = 'BST';
}
else
{
$time_zone = 'GMT';
}
How can i check same functionality in angular 6
i have used daylight time saving check in php using below code
if (date('I', time()))
{
$time_zone = 'BST';
}
else
{
$time_zone = 'GMT';
}
How can i check same functionality in angular 6
Angular is not a language. Angular 6 runs with Typescript which transpiles to javascript. You're looking for a js/ts way of doing this which has already been answered.
How to check if the DST (Daylight Saving Time) is in effect and if it is what's the offset?