Minimal alternative to Google Analytics based on Vue.js and MongoDB.
This project does not use semantic versioning until v1 is officially released, so please check the changelog carefully before each upgrade to see if it is still working properly.
Vue.js is in the transition phase from v2 to v3, and the project will continue to be based on v2 temporarily because the adaptation of the community ecosystem is not stable yet.
Go to documentation site for detailed instructions.
git clone https://github.com/dsrkafuu/aofuji-analytics.git
cd aofuji-analytics
Checkout the latest release after cloned:
git checkout v0.1.0
You can get the latest release tag at release page.
Create a .env.production
file and set the only required environment variable DATABASE_URL
. If you're using a locally installed MongoDB server, your setup looks like this:
echo "DATABASE_URL=mongodb://username:password@localhost:27017/dbname" > .env.production
Check out the Environment Variables for more optional variables.
npm ci
npm run build
npm start
When the server starts up at port 3000, you can expose it directly to the public network (not recommended) or provide it to a reverse proxy.
git fetch
git checkout v0.1.1 # latest tags will show in terminal when fetch
npm ci
npm run build
npm start
First you need to fork this repo and clone it.
Then create a .env.development
then set the development environment variables above. Check the Environment Variables section for more details.
After these, you can simply:
npm install
npm run dev
Local MongoDB server is also needed.
This project uses husky and lint-staged to format source code, so the git commands may be slow due to the Prettier formatting workflow.
render
name => components
props => data => computed => watch
lifecycle functions
methods
All basic components in @/components
should not use scoped styles, styles of those needs to be named like a-component-ctx
.
Alternatively, all view components in @/views
should use scoped styles.
This project is released under MIT License
, for more information read the LICENSE.
Copyright © 2020-present DSRKafuU (https://dsrkafuu.su)