Socket
Socket
Sign inDemoInstall

to-percent-js

Package Overview
Dependencies
2
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.2 to 0.3.3

3

build/cjs/src/__tests__/test.js

@@ -89,2 +89,5 @@ "use strict";

});
it("Test zero", function () {
(0, _chai.expect)((0, _index.toInt)("-0")).to.equal(0);
});
});

@@ -91,0 +94,0 @@ describe("Get Num", function () {

2

build/cjs/src/index.js

@@ -44,3 +44,3 @@ "use strict";

if (maybeFloat === maybeInt && maybeInt + "" === maybeString) {
if (maybeFloat === maybeInt && (maybeInt + "" === maybeString || 0 === maybeInt)) {
return maybeInt;

@@ -47,0 +47,0 @@ } else {

@@ -85,2 +85,5 @@ "use strict";

});
it("Test zero", function () {
expect(toInt("-0")).to.equal(0);
});
});

@@ -87,0 +90,0 @@ describe("Get Num", function () {

@@ -29,3 +29,3 @@ import _typeof from "reshow-runtime/es/helpers/typeof";

if (maybeFloat === maybeInt && maybeInt + "" === maybeString) {
if (maybeFloat === maybeInt && (maybeInt + "" === maybeString || 0 === maybeInt)) {
return maybeInt;

@@ -32,0 +32,0 @@ } else {

{
"name": "to-percent-js",
"version": "0.3.2",
"version": "0.3.3",
"description": "Change number to percentage.",

@@ -5,0 +5,0 @@ "repository": "react-atomic/react-atomic-organism",

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