@villedemontreal/workit-core
Version:
This package provides default and no-op implementations of the WorkIt types for client packages.
49 lines • 1.54 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.constants = exports.Constants = void 0;
/*
* Copyright (c) 2025 Ville de Montreal. All rights reserved.
* Licensed under the MIT license.
* See LICENSE file in the project root for full license information.
*/
class Constants {
constructor() {
this._envs = {
// ==========================================
// "development" seems to be the standard Node label, not "dev".
// The node-config library uses this :
// https://github.com/lorenwest/node-config/wiki/Configuration-Files#default-node_env
// ==========================================
dev: 'development',
accept: 'acceptation',
// ==========================================
// "production" seems to be the standard Node label, not "prod".
// ==========================================
prod: 'production',
};
}
/**
* Singleton
* @readonly
* @static
* @type {Constants}
* @memberof Constants
*/
static get instance() {
if (!this._instance) {
this._instance = Object.freeze(new Constants());
}
return this._instance;
}
/**
* Known environment types
* @readonly
* @memberof Constants
*/
get envs() {
return this._envs;
}
}
exports.Constants = Constants;
exports.constants = Constants.instance;
//# sourceMappingURL=index.js.map