Socket
Socket
Sign inDemoInstall

browserslist-ga

Package Overview
Dependencies
99
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.12 to 0.0.13

4

package.json
{
"name": "browserslist-ga",
"version": "0.0.12",
"version": "0.0.13",
"description": "Target browsers tailored to your audience",

@@ -8,3 +8,3 @@ "repository": "github:browserslist/browserslist-ga",

"bin": {
"browserslist-ga": "./index.js"
"browserslist-ga": "index.js"
},

@@ -11,0 +11,0 @@ "engines": {

@@ -26,3 +26,3 @@ <img width="520" height="68" src="./logo.svg" alt="Browserslist-GA logo">

You'll be asked to login with your Google Account. Your access token will only be used locally to generate a `browserslist-stats.json` file in the root of your project. After finishing the steps, you can use your stats with Browserlist by adding the following to your [Browserslist config](https://github.com/ai/browserslist#config-file):
You'll be asked to login with your Google Account (please see [this issue](https://github.com/browserslist/browserslist-ga/issues/26#issuecomment-568583144) if you are unable to sign in). Your access token will only be used locally to generate a `browserslist-stats.json` file in the root of your project. After finishing the steps, you can use your stats with Browserlist by adding the following to your [Browserslist config](https://github.com/ai/browserslist#config-file):

@@ -29,0 +29,0 @@ ```yaml

@@ -20,13 +20,13 @@ /* Code adapted from caniuse.com with permission */

helpers.distributeIOS = function() {
if (!("iOS Safari" in browsers) || !("iOS app" in browsers)) {
if (!("Safari on iOS" in browsers) || !("iOS app" in browsers)) {
return;
}
var iOSTotal = browsers["iOS Safari"].total;
var iOSTotal = browsers["Safari on iOS"].total;
var appTotal = browsers["iOS app"].total;
// Distribute iOS app points
for (var o in browsers["iOS Safari"]) {
var val = browsers["iOS Safari"][o];
for (var o in browsers["Safari on iOS"]) {
var val = browsers["Safari on iOS"][o];
var ratio = val / iOSTotal;
browsers["iOS Safari"][o] += Math.round(ratio * appTotal);
browsers["Safari on iOS"][o] += Math.round(ratio * appTotal);
}

@@ -241,5 +241,5 @@ delete browsers["iOS app"];

// all apps on ios must use safari engine by apple rules
browser = "iOS Safari";
browser = "Safari on iOS";
} else if (browser == "Safari (in-app)") {
browser = "iOS Safari";
browser = "Safari on iOS";
} else if (browser == "BlackBerry") {

@@ -329,3 +329,3 @@ browser = "Blackberry Browser";

case "iOS Safari":
case "Safari on iOS":
v_num = helpers.getIosSafariVersion(os_ver);

@@ -332,0 +332,0 @@ break;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc