
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@atxmtx/metrics
Advanced tools
Google Analytics event tracking for Atom packages
npm install @atxmtx/metrics -S
Once the Metrics class has been instantiated, events can be fired from anywhere in your package.
// JavaScript
import Metrics from '@atxmtx/metrics';
export async function activate() {
const ga = new Metrics('UA-XXXX-Y');
ga.event({
category: 'Demo',
action: 'Package activated!'
});
};
# CoffeeScript
const Metrics = require "@atxmtx/metrics"
module.exports =
activate: () ->
ga = new Metrics("UA-XXXX-Y");
ga.event {
category: "Demo"
action: "Package activated!"
}
Command metrics allow simple tracking of invoked package commands. In the following example, all commands provided by the settings-view
package will be tracked by Google Analytics.
// JavaScript
import Metrics from '@atxmtx/metrics';
export async function activate() {
new Metrics('UA-XXXX-Y', {
commandCategory: 'Settings View Commands',
commandAction: [
'settings-view:*'
]
});
};
# CoffeeScript
const Metrics = require "@atxmtx/metrics"
module.exports =
activate: () ->
new Metrics('UA-XXXX-Y',
commandCategory: 'Settings View Commands'
commandAction: [
'settings-view:*'
])
Note: Invoking commands from tool-bar
packages is currently not supported!
Usage: new Metrics(trackingID: string, options: object)
Instantiates class and adds event listeners, unless option.muted
is used
Usage: listen()
Manuall add event listener, e.g. for when option.muted
is true
Usage: mute()
Removes event listener
Usage: event({ category: string, action: string, label?: string, value?: number})
Sends an event to Google Analystics
Type: boolean
Default: false
Used to send a random number in GET requests to ensure browsers and proxies don't cache hits.
Type: string | string[]
Used to track specified package commands, supports wildcards (e.g. my-package:*
).
Type: string
Default: Package Command
Default event category for package commands.
Type: string
Specifies a package setting in which the user can deny tracking, e.g. in compliance with the GDPR.
Type: boolean
Default: false
Skips sending the actual request to Google Analytics.
Type: boolean
Default: false
Skips adding event listeners when the class is instantiated.
Type: boolean
Default: false
Enables tracking if the current window is in development mode.
Type: boolean
Default: false
Enables tracking if current window is running specs.
This work is dual-licensed under The MIT License and the GNU General Public License, version 2.0
FAQs
Google Analytics event tracking for Atom packages
The npm package @atxmtx/metrics receives a total of 1 weekly downloads. As such, @atxmtx/metrics popularity was classified as not popular.
We found that @atxmtx/metrics demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.