DavidWells / analytics

Lightweight analytics abstraction layer for tracking page views, custom events, & identifying visitors
https://getanalytics.io
MIT License
2.46k stars 244 forks source link

Contradicting types for `config.version` #435

Closed jamesbeith closed 5 months ago

jamesbeith commented 6 months ago

In the API reference docs, config.version is typed as a string.

https://github.com/DavidWells/analytics/blob/82216bfad172fa834b1b7beb030be4e41ed73ed9/site/main/source/api.md?plain=1#L31

However, the Using in your app example docs on the homepage is using a integer.

https://github.com/DavidWells/analytics/blob/209e6fd8e3e33b61297cf0d41f69a3c94b9d89c2/site/main/source/index.mdx?plain=1#L67

DavidWells commented 6 months ago

Ah word. Good catch.

Should be string|number. Really it can be whatever you wish. Some like semver, some like dates, some like numbers

DavidWells commented 5 months ago

Published updated lib