Skip to content

Commit b6a54a1

Browse files
author
Brian Genisio
committed
Adding a package.json file
1 parent be7ed3a commit b6a54a1

File tree

3 files changed

+20
-2
lines changed

3 files changed

+20
-2
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
node_modules
2+

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,10 @@ The server will start on `http://localhost:3000` by default.
117117

118118
The server provides a `POST /message` endpoint that allows you to send real-time messages to connected clients. This can be used to signal changes in the client during events like "Run" or "Submit". When a message is sent, the preview window with the application open will display an alert with the message.
119119

120-
It uses the `ws` package, so if you want to use it, install `ws`.
120+
It uses the `ws` package, so if you want to use it, install the packages (but this is optional).
121121

122122
```
123-
npm install ws
123+
npm install
124124
```
125125

126126
#### Endpoint: `POST /message`

package.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"name": "bespoke-template",
3+
"version": "0.0.1",
4+
"description": "Bespoke template with local development server and WebSocket messaging",
5+
"main": "server.js",
6+
"scripts": {
7+
"start": "node server.js",
8+
"dev": "node server.js"
9+
},
10+
"keywords": ["bespoke", "template", "development", "server", "websocket"],
11+
"author": "",
12+
"license": "MIT",
13+
"dependencies": {
14+
"ws": "^8.14.2"
15+
}
16+
}

0 commit comments

Comments
 (0)