Template for a basic Collabs app.
Our Quick Start walks through using this template.
First, install Node.js. Then run npm i
.
Runs both servers for testing for the app:
webpack-dev-server
on port 3000, to serve static files.collabs-ws-server
on port 3001, to connect users via aWebSocket server.
Open http://localhost:3000/ to try it out. Use multiple browser windows at once to test collaboration.
You can run the servers separately with npm run start:webpack
and npm run start:ws-server
.
Build the app from src/
, in development mode.
webpack-dev-server
will build for you, so you do not need to do this until you start serving files yourself.
Build the app from src/
, in production mode.
webpack-dev-server
will build for you, so you do not need to do this until you start serving files yourself.
Delete dist/
.
- Code:
src/index.html
: The app's HTML.src/main.ts
: The app's TypeScript code.
- Configuration:
package.json
: npm install file.tsconfig.json
: TypeScript configuration for the app.webpack.config.ts
: Wepback configuration.tsconfig.webpack-config.json
: TypeScript configuration that lets us writewebpack.config.ts
in TypeScript instead of JavaScript.