- JavaScript 55.4%
- Vue 38.9%
- CSS 3.7%
- Dockerfile 1.6%
- HTML 0.4%
|
|
||
|---|---|---|
| .forgejo/workflows | ||
| .vscode | ||
| docker | ||
| src | ||
| tests | ||
| .editorconfig | ||
| .gitattributes | ||
| .gitignore | ||
| bun.lock | ||
| eslint.config.js | ||
| index.html | ||
| jsconfig.json | ||
| nightwatch.conf.cjs | ||
| package.json | ||
| README.md | ||
| spec.md | ||
| vite.config.js | ||
| vitest.config.js | ||
hydraslayer-client
This template should help get you started developing with Vue 3 in Vite.
Recommended IDE Setup
VSCode + Volar (and disable Vetur).
Customize configuration
See Vite Configuration Reference.
Project Setup
bun install
Compile and Hot-Reload for Development
bun dev
By default this proxies /api to http://localhost:3000/
Host the API server either by running nodewrangler yourself or use the docker compose command described below.
Alternatively you can reconfigure the proxy in vite.config.js to point to an existing server.
Compile and Minify for Production
bun run build
Run Unit Tests with Vitest
bun test:unit
# Run with coverage reporting
bun coverage:unit
Run End-to-End Tests with Nightwatch
The server component needs to run on port 3000 with the seed data set up for these tests to work. See the Docker section below.
# When using CI, the project must be built first.
bun run build
# Runs the end-to-end tests
bun test:e2e
# Runs the tests only on Chrome
bun test:e2e --env chrome
# Runs the tests of a specific file
bun test:e2e tests/e2e/login.js
# Runs the tests in debug mode
bun test:e2e --debug
Lint with ESLint
bun lint
Build and run with Docker
Run the client and server image with client hosted on http://localhost/ and api server on http://localhost:3000/
docker compose -f docker/compose.yaml up --build
In order for this to work you will need to authenticate with ghcr.io. You can do that by creating a personal access token with read:packages scope and logging in using it as the password with
docker login ghcr.io
To only run the api server use
docker compose -f docker/compose.yaml up server