elegance-js 1.1.2 → 1.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/build.d.ts CHANGED
@@ -12,6 +12,7 @@ type CompilationOptions = {
12
12
  runServer: boolean;
13
13
  root?: string;
14
14
  port?: number;
15
+ host?: string;
15
16
  };
16
17
  hotReload?: {
17
18
  port: number;
package/dist/build.mjs CHANGED
@@ -276,7 +276,7 @@ var MIME_TYPES = {
276
276
  ".ico": "image/x-icon",
277
277
  ".txt": "text/plain; charset=utf-8"
278
278
  };
279
- function startServer({ root, port = 3e3, host = "0.0.0.0", environment = "production" }) {
279
+ function startServer({ root, port = 3e3, host = "localhost", environment = "production" }) {
280
280
  if (!root) throw new Error("Root directory must be specified.");
281
281
  const requestHandler = async (req, res) => {
282
282
  try {
@@ -1023,7 +1023,8 @@ var compile = async (props) => {
1023
1023
  startServer({
1024
1024
  root: props.server.root ?? DIST_DIR,
1025
1025
  environment: props.environment,
1026
- port: props.server.port ?? 3e3
1026
+ port: props.server.port ?? 3e3,
1027
+ host: props.server.host ?? "localhost"
1027
1028
  });
1028
1029
  }
1029
1030
  if (watch) {
@@ -279,7 +279,7 @@ var MIME_TYPES = {
279
279
  ".ico": "image/x-icon",
280
280
  ".txt": "text/plain; charset=utf-8"
281
281
  };
282
- function startServer({ root, port = 3e3, host = "0.0.0.0", environment: environment2 = "production" }) {
282
+ function startServer({ root, port = 3e3, host = "localhost", environment: environment2 = "production" }) {
283
283
  if (!root) throw new Error("Root directory must be specified.");
284
284
  const requestHandler = async (req, res) => {
285
285
  try {
@@ -1026,7 +1026,8 @@ var compile = async (props) => {
1026
1026
  startServer({
1027
1027
  root: props.server.root ?? DIST_DIR,
1028
1028
  environment: props.environment,
1029
- port: props.server.port ?? 3e3
1029
+ port: props.server.port ?? 3e3,
1030
+ host: props.server.host ?? "localhost"
1030
1031
  });
1031
1032
  }
1032
1033
  if (watch) {
@@ -16,7 +16,7 @@ var MIME_TYPES = {
16
16
  ".ico": "image/x-icon",
17
17
  ".txt": "text/plain; charset=utf-8"
18
18
  };
19
- function startServer({ root, port = 3e3, host = "0.0.0.0", environment = "production" }) {
19
+ function startServer({ root, port = 3e3, host = "localhost", environment = "production" }) {
20
20
  if (!root) throw new Error("Root directory must be specified.");
21
21
  const requestHandler = async (req, res) => {
22
22
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "elegance-js",
3
- "version": "1.1.2",
3
+ "version": "1.1.3",
4
4
  "description": "Web-Framework",
5
5
  "type": "module",
6
6
  "bin": {