Is there such a thing as public static constants in TypeScript? I have a class that looks like:
export class Library {
public static BOOK_SHELF_NONE: stri
Here's what's this TS snippet compiled into (via TS Playground):
define(["require", "exports"], function(require, exports) {
var Library = (function () {
function Library() {
}
Library.BOOK_SHELF_NONE = "None";
Library.BOOK_SHELF_FULL = "Full";
return Library;
})();
exports.Library = Library;
});
As you see, both properties defined as public static are simply attached to the exported function (as its properties); therefore they should be accessible as long as you properly access the function itself.