jakeydevs / analytics

🛠 Simple site analytics that you collect and host yourself!
https://analytics.jakey.dev
MIT License
4 stars 1 forks source link

Readme needs updating with limitations #3

Open ukmadlz opened 3 years ago

ukmadlz commented 3 years ago

Just scanning the parse code, the readme should state this doesn't work with an SPA for time on page, or if they leave with a 2nd page render.

jakeydevs commented 3 years ago

Should we create a feature which will allow the system to create another Pageview programatically? Just ping a function and then it records another pageview? Could also take in new info such as new path requested?

jakeydevs commented 3 years ago

Will mean we should move our page recording stuff outside of the middleware directly (which should be done anyway when we refactor) and into its own Action class.

Then we can create a helper function which should allow us to ping the pageview model creation whenever we need it - which should be more than sufficient for SPA creators!

ukmadlz commented 3 years ago

I believe that should be a stretch/config extension rather than the default. If you want it to be up to the developer to choose how he builds his app, otherwise you're forcing an opinion of how to do it.