From 56fefbdb0db188f895161fdb32e2db1837a65e2c Mon Sep 17 00:00:00 2001 From: Andrea Bogazzi Date: Sun, 19 Aug 2018 08:40:24 +0200 Subject: [PATCH] better jsdocs --- src/shapes/object.class.js | 4 +++- src/static_canvas.class.js | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/shapes/object.class.js b/src/shapes/object.class.js index 25f0c215..05b9ee5d 100644 --- a/src/shapes/object.class.js +++ b/src/shapes/object.class.js @@ -441,7 +441,9 @@ includeDefaultValues: true, /** - * Function that determines clipping of an object (context is passed as a first argument) + * Function that determines clipping of an object (context is passed as a first argument). + * If you are using code minification, ctx argument can be minified/manglied you should use + * as a workaround `var ctx = arguments[0];` in the function; * Note that context origin is at the object's center point (not left/top corner) * @deprecated since 2.0.0 * @type Function diff --git a/src/static_canvas.class.js b/src/static_canvas.class.js index 3e2bd8f9..46d190dd 100644 --- a/src/static_canvas.class.js +++ b/src/static_canvas.class.js @@ -112,7 +112,10 @@ /** * Function that determines clipping of entire canvas area - * Being passed context as first argument. See clipping canvas area in {@link https://github.com/kangax/fabric.js/wiki/FAQ} + * Being passed context as first argument. + * If you are using code minification, ctx argument can be minified/manglied you should use + * as a workaround `var ctx = arguments[0];` in the function; + * See clipping canvas area in {@link https://github.com/kangax/fabric.js/wiki/FAQ} * @deprecated since 2.0.0 * @type Function * @default