Skip to content
This repository has been archived by the owner on Nov 5, 2022. It is now read-only.

Commit

Permalink
Revert the node compatible code. Causing #11
Browse files Browse the repository at this point in the history
  • Loading branch information
jcgregorio committed May 2, 2017
1 parent e8a907f commit b754333
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 11 deletions.
5 changes: 0 additions & 5 deletions canvas.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,6 @@
* A polyfill for HTML Canvas features, including
* Path2D support.
*/
var CanvasRenderingContext2D = CanvasRenderingContext2D;
if (CanvasRenderingContext2D == undefined) {
CanvasRenderingContext2D = require('canvas').Context2d;
}

if (CanvasRenderingContext2D.prototype.ellipse == undefined) {
CanvasRenderingContext2D.prototype.ellipse = function(x, y, radiusX, radiusY, rotation, startAngle, endAngle, antiClockwise) {
this.save();
Expand Down
5 changes: 0 additions & 5 deletions canvasv5.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,6 @@
* A polyfill for HTML Canvas features, including
* Path2D support.
*/
var CanvasRenderingContext2D = CanvasRenderingContext2D;
if (CanvasRenderingContext2D == undefined) {
CanvasRenderingContext2D = require('canvas').Context2d;
}

if (CanvasRenderingContext2D.prototype.ellipse == undefined) {
CanvasRenderingContext2D.prototype.ellipse = function(x, y, radiusX, radiusY, rotation, startAngle, endAngle, antiClockwise) {
this.save();
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "canvas-5-polyfill",
"version": "0.1.2",
"version": "0.1.3",
"description": "Polyfill for HTML 5 Canvas features.",
"main": "canvas.js",
"types": "./canvas.d.ts",
Expand Down

0 comments on commit b754333

Please sign in to comment.