A simple static web page hit tracker using Golang and SQLite, Can tracking different subpages of a static web page.
- Build a simple backend server yourself for tracking page hits
- Use a lightweight database like SQLite
- Fast and easy to use
- Track static web subpages
- dokcer with docker-compose
- Install docker and docker-compose
- Clone this repository
- Setting you publishing url in config.json
- "trackerURL": "PUBLISHING_URL"
- Run
bash RUN.sh
to start the server- The server will run on port 8080
Use the following code to track page hits, and replace the PUBLISHING_URL with your publishing url.
<script async src="${ PUBLISHING_URL }/tracker.js"></script>
<span id="page-hit-tracker"></span>