ℹ️ Issues for this repository are tracked on Phabricator - (Click here to open a new one)
The code for the https://wikibase.cloud/ website (previously wbstack.com).
For a detailed explanation on how things work, check out the guide and docs for vue-loader.
This app uses https://cli.vuejs.org.
docker compose run ui npm install
docker compose up -d
docker compose run ui npm run <command>
npm install
npm run serve
npm run build
This ui uses Mock Service Worker (https://mswjs.io/) to mock the backend api for test purposes.
To run dev server with mocked api, set env variable API_MOCK
to a value that evaluates to true
.
This can either be done at runtime using npm, or in .env
for docker-compose.
VUE_APP_API_MOCK=1 npm run serve
Currently, logging in using any email and password will behave as if the same user is always logging in.
Created wikis by that user will live in local storage (msw-myWikis
key)
Backend api mocks live in /src/backend/mocks/default_handlers.js
.
Note
Firefox blocks service workers as long as we use localhost
for local development. The only solution is to use
chrom(ium) for now.
rm -r node_modules
docker compose run ui npm install
docker compose --profile browser-tests up -d
docker compose exec -it ui npm run test:e2e
docker compose --profile browser-tests down