AlexRazor1337 / od-server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simple WS server for browser game

Main elements are:

  • pnpm - efficient packet manager
  • nodemon - restart your app when code changes
  • eslint and prettier - for code formatting and keeping style uniform
  • husky - pre-commit hooks with auto fixing and formating

NOTE: pnpm and npm can be used interchangeably.

Development

  1. Clone the repo: git clone --recursive git@github.com:AlexRazor1337/od-server.git
  2. Install deps: npm i
    2. Install husky: npm run prepare
  3. Fill the .env file:
    NODE_ENV=development
    ADMIN_PORT=8001
    ADMIN_PASSWORD=testtest
    PORT=3000
    CORS_ORIGIN=localhost:3000
  4. Run server in development mode: npm run dev
  5. Now you can open the game in the browser via localhost:3000
    To skip login, use localhost:3000/?dev

About


Languages

Language:JavaScript 100.0%