feat: add @scarf/scarf install analytics - #849
Closed
nelson-parente wants to merge 1 commit into
Closed
Conversation
Adds scarf-js as a postinstall-only dependency to give Dapr maintainers anonymized SDK install counts (OS, package version; request IP is used by Scarf for company-level aggregation and not stored). - allowTopLevel: false — installs inside a js-sdk checkout are not reported - Opt-outs honored: SCARF_ANALYTICS=false, DO_NOT_TRACK=1, consumer scarfSettings.enabled=false, or --ignore-scripts - README gains an Installation Analytics disclosure section Signed-off-by: nelson.parente <nelson_parente@live.com.pt>
nelson-parente
marked this pull request as ready for review
August 17, 2026 08:56
Contributor
Author
|
closing ... @WhitWaldo flagged that npm 12 (Jul 2026) blocks dependency install scripts by default, which kills scarf-js's mechanism |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Proposal: add
@scarf/scarfinstall-time analytics to@dapr/dapr.Why: npm exposes only aggregate download counts, so the project has no visibility into SDK adoption. Dapr already uses Scarf for analytics elsewhere — the docs.dapr.io footer pixel, Maven Central download stats for the Java SDK, and Scarf.sh is listed as a community-managed tool in COMMUNITY-MANAGER.md. This extends the same visibility to the JS SDK. Related: dapr/cli#1689 routes CLI install-script downloads through a Scarf gateway.
What it does:
@dapr/dapris installed as a dependency of another project — no runtime footprint, nothing imported at runtime.allowTopLevel: false— contributors runningnpm installinside a js-sdk checkout are not reported.SCARF_ANALYTICS=false, theDO_NOT_TRACK=1standard,"scarfSettings": { "enabled": false }in the consumer's package.json, or installing with--ignore-scripts.