@rws-aoa/utils
Version:
Utilities for RWS AOA libraries and applications
81 lines (75 loc) • 1.84 kB
JavaScript
export { capitalizeFirstLetter, snakeToCamelCase } from '@sapphire/utilities';
var __defProp = Object.defineProperty;
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
// src/IsDevEnv.ts
var isDevEnv = process.env.NODE_ENV === "development" ? true : process.env.NODE_ENV === "test";
// src/IsTestEnv.ts
var isTestEnv = process.env.NODE_ENV === "test";
// src/TimeUtils.ts
var SECOND = 1e3;
var MINUTE = SECOND * 60;
var HOUR = MINUTE * 60;
var DAY = HOUR * 24;
var DAYS = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
var MONTHS = [
"January",
"February",
"March",
"April",
"May",
"June",
"July",
"August",
"September",
"October",
"November",
"December"
];
var DAYS_NL = ["Zondag", "Maandag", "Dinsdag", "Woensdag", "Donderdag", "Vrijdag", "Zaterdag"];
var MONTHS_NL = [
"Januari",
"Februari",
"Maart",
"April",
"Mei",
"Juni",
"July",
"Augustus",
"September",
"October",
"November",
"December"
];
// src/WindowLocationService.ts
var WindowLocationService = class {
static {
__name(this, "WindowLocationService");
}
static get origin() {
return this.getLocation().origin;
}
static get path() {
return this.getLocation().pathname;
}
static get hash() {
return this.getLocation().hash;
}
static get search() {
return this.getLocation().search;
}
static get host() {
return this.getLocation().host;
}
static get href() {
return this.getLocation().href;
}
static redirectTo(url) {
this.getLocation().assign(url);
}
static getLocation() {
return window.location;
}
};
export { DAY, DAYS, DAYS_NL, HOUR, MINUTE, MONTHS, MONTHS_NL, SECOND, WindowLocationService, isDevEnv, isTestEnv };
//# sourceMappingURL=index.js.map
//# sourceMappingURL=index.js.map