moving front app to subfolder. add webpack config with watch and dev-server mode. moving deploy things in subfolder

This commit is contained in:
Dzmitry_Tamashevich@epam.com
2020-11-29 21:02:37 +03:00
committed by Daniel Hutzel
parent 0e86e1e1fd
commit dbe4b8a7bd
70 changed files with 2755 additions and 3 deletions

View File

@@ -0,0 +1,28 @@
const getDurationInMilliseconds = (start) => {
const NS_PER_SEC = 1e9; // convert to nanoseconds
const NS_TO_MS = 1e6; // convert to milliseconds
const diff = process.hrtime(start);
return (diff[0] * NS_PER_SEC + diff[1]) / NS_TO_MS;
};
const getFormattedDateTime = () => {
let currentDateTime = new Date();
let formattedDateTime =
currentDateTime.getFullYear() +
"-" +
(currentDateTime.getMonth() + 1) +
"-" +
currentDateTime.getDate() +
" " +
currentDateTime.getHours() +
":" +
currentDateTime.getMinutes() +
":" +
currentDateTime.getSeconds();
return formattedDateTime;
};
module.exports = {
getFormattedDateTime,
getDurationInMilliseconds,
};