A web-based user interface for Typesense server that provides a simple way to manage and visualize your Typesense data.
- Browse collections and documents
- View collection schemas
- Real-time search functionality
- Dark mode interface
- Configurable connection settings
- Docker-ready deployment
- Docker and Docker Compose (for Docker deployment)
- Node.js 16+ (for local development)
- A running Typesense server instance
- Clone this repository:
git clone https://github.com/yourusername/typesense-ui.git
cd typesense-ui
- Copy
.env.example
to.env
and configure your Typesense connection parameters:
cp .env.example .env
- Run with docker-compose:
docker-compose up
Example docker-compose.yml:
version: '3'
services:
typesense-ui:
build: .
ports:
- "3000:3000"
environment:
- TS_SERVER_KEY=${TS_SERVER_KEY:-your_key_here}
- TS_HOST=${TS_HOST:-localhost}
- TS_PORT=${TS_PORT:-8108}
- TS_PROTOCOL=${TS_PROTOCOL:-http}
- PAGE_LENGTH=${PAGE_LENGTH:-20}
- USE_DEMO=${USE_DEMO:-true}
volumes:
- ./js:/app/js
- ./css:/app/css
- Build the image:
docker build -t typesense-ui .
- Run the container:
docker run -p 3000:3000 \
-e TS_SERVER_KEY=your_key_here \
-e TS_HOST=localhost \
-e TS_PORT=8108 \
-e TS_PROTOCOL=http \
-e PAGE_LENGTH=20 \
-e USE_DEMO=false \
typesense-ui
- Install dependencies:
npm install
-
Configure environment variables in
.env
-
Start the development server:
npm start
Variable | Description | Default |
---|---|---|
TS_SERVER_KEY |
Your Typesense API key | your_key_here |
TS_HOST |
Typesense server hostname | localhost |
TS_PORT |
Typesense server port | 8108 |
TS_PROTOCOL |
Protocol to use (http/https) | http |
PAGE_LENGTH |
Number of items per page | 20 |
USE_DEMO |
Whether to use demo mode | true |
TS_SERVER_KEY=xyz123
TS_HOST=typesense.example.com
TS_PORT=8108
TS_PROTOCOL=https
PAGE_LENGTH=20
USE_DEMO=false
The project uses a simple Express server to serve the UI and handle environment variable injection. For development:
- The Docker setup includes volume mounts for the
js
andcss
directories - Changes to these directories will be reflected immediately without rebuilding
- The application will be available at http://localhost:3000
.
├── Dockerfile
├── docker-compose.yml
├── package.json
├── server.js
├── .env
├── .gitignore
├── css/
│ └── style-dark.css
└── js/
├── typesense-api.js
├── vdom.js
├── components.js
└── main.js
-
Connection refused:
- Verify Typesense server is running
- Check if the host/port configuration is correct
- Ensure firewall rules allow the connection
-
Authentication failed:
- Verify your API key is correct
- Check if the API key has appropriate permissions
-
CORS issues:
- Ensure your Typesense server is configured to accept requests from the UI's domain
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Typesense
- Uses Express for serving the UI
- Docker support for easy deployment
- Inspired by bfritscher/typesense-dashboard - A comprehensive Typesense Dashboard built with Vue and Electron