This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const DefaultTimestamp = "YYYY-MM-DD H:mm:ss"; | |
/** | |
* Server Related configurations. | |
*/ | |
const ServerConfig = { | |
/** | |
* Middleware to handle server under maintenance mood | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = { | |
chainWebpack: config => { | |
config | |
.plugin('fork-ts-checker') | |
.tap(args => { | |
args[0].tsconfig = './path/to/tsconfig.json'; | |
return args; | |
}); | |
} | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name example.com; | |
charset utf-8; | |
root {{app_root}}/dist; | |
index index.html index.htm; | |
# Always serve index.html for any request | |
location / { | |
root {{app_root}}/dist; | |
try_files $uri /index.html; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
listen 80; | |
server_name example.com; | |
charset utf-8; | |
root {{app_root}}/dist; | |
index index.html index.htm; | |
# Always serve index.html for any request | |
location / { | |
root {{app_root}}/dist; | |
try_files $uri /index.html; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Compare two objects. | |
* @param source | |
* @param compare | |
*/ | |
export function isSameObjectByJson(source: Record<any, any>, compare: Record<any, any>) { | |
let s: string, c: string; | |
try { | |
s = JSON.stringify(source, null, 0); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* --- STAGE: RFC --- | |
* Xpresser Spin is a one file xpresser setup command. | |
* This will become the fastest way to spin up an expressjs fully backed MVC server in nodejs. | |
* @example | |
* xjs spin app.ts // will read the file and start xpresser. | |
*/ | |
// For types sake | |
type DollarSign = any; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
domain { | |
root * /var/patch/dcc-front-vite/dist | |
file_server | |
try_files {path} /index.html | |
tls /etc/caddy/certs/tdm.pem /etc/caddy/certs/tdm.key | |
} |