basic-node-server 1.0.3 → 1.0.5
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/README.md +6 -5
- package/{index.js → bns.js} +1 -1
- package/index.html +35 -1
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -6,14 +6,15 @@ If no path is given, it will serve the index.html file.
|
|
|
6
6
|
|
|
7
7
|
## How to use
|
|
8
8
|
```
|
|
9
|
-
|
|
9
|
+
node bns [port]
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
The [port] argument is optional. If no port is given, it will default to 3000.
|
|
13
13
|
|
|
14
14
|
For example, if you want to serve the current directory on port 8080, you would run:
|
|
15
|
+
|
|
15
16
|
```
|
|
16
|
-
|
|
17
|
+
node bns 8080
|
|
17
18
|
```
|
|
18
19
|
|
|
19
20
|
## NPM
|
|
@@ -24,8 +25,8 @@ npm install basic-node-server
|
|
|
24
25
|
|
|
25
26
|
```
|
|
26
27
|
|
|
27
|
-
Then,
|
|
28
|
+
Then, you can run it from your project directory:
|
|
28
29
|
|
|
29
30
|
```
|
|
30
|
-
node node_modules/basic-node-server/
|
|
31
|
-
```
|
|
31
|
+
node node_modules/basic-node-server/bns [port]
|
|
32
|
+
```
|
package/{index.js → bns.js}
RENAMED
package/index.html
CHANGED
|
@@ -1 +1,35 @@
|
|
|
1
|
-
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
|
|
3
|
+
<h1>Basic Node Server</h1>
|
|
4
|
+
|
|
5
|
+
<p>
|
|
6
|
+
Basic node server for everyone.
|
|
7
|
+
<br>
|
|
8
|
+
Basic node server simply hosts and serves files from the current project directory through HTTP.
|
|
9
|
+
<br>
|
|
10
|
+
If no path is given, it will serve the index.html file.
|
|
11
|
+
</p>
|
|
12
|
+
|
|
13
|
+
<h2>How to use</h2>
|
|
14
|
+
<pre>
|
|
15
|
+
node bns [port]
|
|
16
|
+
</pre>
|
|
17
|
+
<p>
|
|
18
|
+
The [port] argument is optional. If no port is given, it will default to 3000.
|
|
19
|
+
<br>
|
|
20
|
+
For example, if you want to serve the current directory on port 8080, you would run:
|
|
21
|
+
</p>
|
|
22
|
+
<pre>
|
|
23
|
+
node bns 8080
|
|
24
|
+
</pre>
|
|
25
|
+
|
|
26
|
+
<h2>NPM</h2>
|
|
27
|
+
<pre>
|
|
28
|
+
npm install basic-node-server
|
|
29
|
+
</pre>
|
|
30
|
+
<p>
|
|
31
|
+
Then, you can run it from your project directory:
|
|
32
|
+
</p>
|
|
33
|
+
<pre>
|
|
34
|
+
node node_modules/basic-node-server/bns [port]
|
|
35
|
+
</pre>
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "basic-node-server",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "
|
|
5
|
-
"main": "
|
|
3
|
+
"version": "1.0.5",
|
|
4
|
+
"description": "Basic node server for everyone.",
|
|
5
|
+
"main": "bns.js",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"
|
|
7
|
+
"start": "node bns"
|
|
8
8
|
},
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
@@ -15,4 +15,4 @@
|
|
|
15
15
|
},
|
|
16
16
|
"author": "Baksa Gimm",
|
|
17
17
|
"license": "MIT"
|
|
18
|
-
}
|
|
18
|
+
}
|