@types/lineclip
Advanced tools
+6
-14
@@ -1,15 +0,7 @@ | ||
| declare namespace Lineclip { | ||
| type Point = [number, number]; | ||
| type BoundingBox = [number, number, number, number]; | ||
| type LineClipResult = Point[]; | ||
| export type Point = [number, number]; | ||
| export type BoundingBox = [number, number, number, number]; | ||
| export type LineClipResult = Point[][]; | ||
| export type PolygonClipResult = Point[]; | ||
| function polyline(points: Point[], bbox: BoundingBox, result?: LineClipResult[]): LineClipResult; | ||
| function polygon(points: Point[], bbox: BoundingBox): LineClipResult; | ||
| } | ||
| declare function Lineclip( | ||
| points: Lineclip.Point[], | ||
| bbox: Lineclip.BoundingBox, | ||
| result?: Lineclip.LineClipResult[], | ||
| ): Lineclip.LineClipResult; | ||
| export = Lineclip; | ||
| export function clipPolyline(points: Point[], bbox: BoundingBox, result?: LineClipResult): LineClipResult; | ||
| export function clipPolygon(points: Point[], bbox: BoundingBox): PolygonClipResult; |
| { | ||
| "name": "@types/lineclip", | ||
| "version": "1.1.1", | ||
| "version": "2.0.0", | ||
| "description": "TypeScript definitions for lineclip", | ||
@@ -12,4 +12,10 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/lineclip", | ||
| "url": "https://github.com/devloop01" | ||
| }, | ||
| { | ||
| "name": "Marc Emmanuel", | ||
| "githubUsername": "SheepFromHeaven", | ||
| "url": "https://github.com/SheepFromHeaven" | ||
| } | ||
| ], | ||
| "type": "module", | ||
| "main": "", | ||
@@ -24,4 +30,5 @@ "types": "index.d.ts", | ||
| "dependencies": {}, | ||
| "typesPublisherContentHash": "59f1a21fabcfd5c6d0d434a123b9013841aec2dd8e82ac46ce4b579a75f8d8cd", | ||
| "typeScriptVersion": "4.5" | ||
| "peerDependencies": {}, | ||
| "typesPublisherContentHash": "aaa29cecd4c3c851389cecd874541e9034ca4a95947f909d878188a9e3258532", | ||
| "typeScriptVersion": "5.2" | ||
| } |
+8
-16
@@ -11,25 +11,17 @@ # Installation | ||
| ````ts | ||
| declare namespace Lineclip { | ||
| type Point = [number, number]; | ||
| type BoundingBox = [number, number, number, number]; | ||
| type LineClipResult = Point[]; | ||
| export type Point = [number, number]; | ||
| export type BoundingBox = [number, number, number, number]; | ||
| export type LineClipResult = Point[][]; | ||
| export type PolygonClipResult = Point[]; | ||
| function polyline(points: Point[], bbox: BoundingBox, result?: LineClipResult[]): LineClipResult; | ||
| function polygon(points: Point[], bbox: BoundingBox): LineClipResult; | ||
| } | ||
| export function clipPolyline(points: Point[], bbox: BoundingBox, result?: LineClipResult): LineClipResult; | ||
| export function clipPolygon(points: Point[], bbox: BoundingBox): PolygonClipResult; | ||
| declare function Lineclip( | ||
| points: Lineclip.Point[], | ||
| bbox: Lineclip.BoundingBox, | ||
| result?: Lineclip.LineClipResult[], | ||
| ): Lineclip.LineClipResult; | ||
| export = Lineclip; | ||
| ```` | ||
| ### Additional Details | ||
| * Last updated: Tue, 07 Nov 2023 09:09:38 GMT | ||
| * Last updated: Mon, 09 Mar 2026 10:45:51 GMT | ||
| * Dependencies: none | ||
| # Credits | ||
| These definitions were written by [Sikriti Dakua](https://github.com/devloop01). | ||
| These definitions were written by [Sikriti Dakua](https://github.com/devloop01), and [Marc Emmanuel](https://github.com/SheepFromHeaven). |
Trivial Package
Supply chain riskPackages less than 10 lines of code are easily copied into your own project and may not warrant the additional supply chain risk of an external dependency.
Yes
NaN3546
-0.34%6
-53.85%27
-22.86%1
Infinity%