Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/Make client-side analytics configurable #76

Merged

Conversation

@c-w
Copy link
Member

c-w commented Jan 25, 2019

The doccano application currently contains Google Analytics with a hard-coded tracking ID. This means that every deployment of doccano will send analytics to the same account. In order to support new deployments of doccano bringing their own analytics, this change makes the Google Analytics tracking ID configurable via a setting.

Additionally, the Google Analytics Javascript will now only be included in the page if the tracking ID is present which means that deployments can also opt-out of Google Analytics altogether.

For users who're looking for an alternative to Google Analytics, this change also adds an option to use Azure Application Insights for client-side monitoring.

@c-w c-w changed the title Feature/Make Google Analytics configurable Feature/Make client-side analytics configurable Jan 27, 2019
@BrambleXu BrambleXu added this to PR Status in v1.0.0 Jan 28, 2019
@c-w c-w force-pushed the CatalystCode:feature/configurable-google-analytics branch from 543b91a to 7f6cce2 Jan 28, 2019
@c-w c-w force-pushed the CatalystCode:feature/configurable-google-analytics branch from c6b5174 to e4fd74e Jan 28, 2019
@Hironsan

This comment has been minimized.

Copy link
Member

Hironsan commented Jan 29, 2019

The doccano application currently contains Google Analytics with a hard-coded tracking ID.

To tell the truth, I embedded the hard-coded tracking ID for knowing how many people are using doccano. Through Google Analytics, I can know the number and it motivated me a lot:

image

But I can understand what you say. This feature is useful for people who want to set their own ID.

Hmmm...

Is there any way to know how many users using doccano but at the same time the user can set their own ID?

@Hironsan Hironsan merged commit 97b435d into doccano:master Jan 29, 2019
2 checks passed
2 checks passed
Travis CI - Pull Request Build Passed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@Hironsan

This comment has been minimized.

Copy link
Member

Hironsan commented Jan 29, 2019

No problem. I really appreciate your help.

@c-w c-w deleted the CatalystCode:feature/configurable-google-analytics branch Jan 29, 2019
@c-w

This comment has been minimized.

Copy link
Member Author

c-w commented Jan 29, 2019

Wow, great to see the usage. In any case, even after this merge, the tracking ID still defaults to yours; the user actively must set the environment variable to an empty string to remove the tracking (like GOOGLE_TRACKING_ID=""). Hope that helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
v1.0.0
PR Status
3 participants
You can’t perform that action at this time.