Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

turf-is-clockwise

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

turf-is-clockwise - npm Package Compare versions

Comparing version 0.1.2 to 1.0.0

bench.js

3

package.json
{
"name": "turf-is-clockwise",
"version": "0.1.2",
"version": "1.0.0",
"description": "turf isClockwise module",

@@ -28,4 +28,5 @@ "main": "index.js",

"devDependencies": {
"benchmark": "^1.0.0",
"tape": "^2.13.4"
}
}

@@ -1,14 +0,14 @@

var test = require('tape')
var isClockwise = require('./')
var test = require('tape');
var isClockwise = require('./');
test('isClockwise', function(t){
var ring = [[0,0],[1,1],[1,0],[0,0]]
var clockwise = isClockwise(ring)
t.equal(clockwise, true, 'should take a ring and return clockwise true')
var ring = [[0,0],[1,1],[1,0],[0,0]];
var clockwise = isClockwise(ring);
t.equal(clockwise, true, 'should take a ring and return clockwise true');
var ring = [[0,0],[1,0],[1,1],[0,0]]
var counterClockwise = isClockwise(ring)
t.equal(counterClockwise, false, 'should take a ring and return clockwise false')
var ring = [[0,0],[1,0],[1,1],[0,0]];
var counterClockwise = isClockwise(ring);
t.equal(counterClockwise, false, 'should take a ring and return clockwise false');
t.end()
t.end();
})
SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc