{"record":{"id":"bec15f6407e3f900","repo":"greensock/GSAP","slug":"please-gsap-registerplugin-customease","errorCode":null,"errorMessage":"Please gsap.registerPlugin(CustomEase)","messagePattern":"Please gsap\\.registerPlugin\\(CustomEase\\)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/CustomEase.js","lineNumber":21,"sourceCode":" * https://gsap.com\n *\n * @license Copyright 2008-2026, GreenSock. All rights reserved.\n * Subject to the terms at https://gsap.com/standard-license\n * @author: Jack Doyle, jack@greensock.com\n*/\n/* eslint-disable */\n\nimport { stringToRawPath, rawPathToString, transformRawPath } from \"./utils/paths.js\";\n\nlet gsap, _coreInitted,\n\t_getGSAP = () => gsap || (typeof(window) !== \"undefined\" && (gsap = window.gsap) && gsap.registerPlugin && gsap),\n\t_initCore = () => {\n\t\tgsap = _getGSAP();\n\t\tif (gsap) {\n\t\t\tgsap.registerEase(\"_CE\", CustomEase.create);\n\t\t\t_coreInitted = 1;\n\t\t} else {\n\t\t\tconsole.warn(\"Please gsap.registerPlugin(CustomEase)\");\n\t\t}\n\t},\n\t_bigNum = 1e20,\n\t_round = value => ~~(value * 1000 + (value < 0 ? -.5 : .5)) / 1000,\n\t_bonusValidated = 1, //<name>CustomEase</name>\n\t_numExp = /[-+=.]*\\d+[.e\\-+]*\\d*[e\\-+]*\\d*/gi, //finds any numbers, including ones that start with += or -=, negative numbers, and ones in scientific notation like 1e-8.\n\t_needsParsingExp = /[cLlsSaAhHvVtTqQ]/g,\n\t_findMinimum = values => {\n\t\tlet l = values.length,\n\t\t\tmin = _bigNum,\n\t\t\ti;\n\t\tfor (i = 1; i < l; i += 6) {\n\t\t\t+values[i] < min && (min = +values[i]);\n\t\t}\n\t\treturn min;\n\t},\n\t//takes all the points and translates/scales them so that the x starts at 0 and ends at 1.\n\t_normalize = (values, height, originY) => {","sourceCodeStart":3,"sourceCodeEnd":39,"githubUrl":"https://github.com/greensock/GSAP/blob/13e2b790546426a1a2e0e9b409f3f8dc6d6611f2/src/CustomEase.js#L3-L39","documentation":"CustomEase requires a GSAP core instance to register its \"_CE\" ease parser. _initCore warns when gsap cannot be found (window.gsap missing or registerPlugin unavailable), because without core the ease cannot hook into GSAP.","triggerScenarios":"Importing CustomEase but never calling gsap.registerPlugin(CustomEase); loading CustomEase before the gsap core script; running in an environment without window (SSR); a custom gsap build without registerPlugin.","commonSituations":"Script tag order wrong (CustomEase before gsap.js); bundler importing CustomEase from 'gsap/all' but gsap from a different copy; forgetting registration entirely.","solutions":["Call gsap.registerPlugin(CustomEase) at startup before creating eases","Ensure gsap core is loaded/imported before CustomEase initialization","Check window.gsap exists when using script tags","Use the same gsap instance everywhere (single package version)"],"exampleFix":"// before\nimport { CustomEase } from 'gsap/all'; // gsap core never imported\n// after\nimport { gsap, CustomEase } from 'gsap/all';\ngsap.registerPlugin(CustomEase);\nconst ease = CustomEase.create('myEase', 'M0,0 C0.1,0 ...');","handlingStrategy":"validation","validationCode":"if (typeof gsap === 'undefined' || !gsap.registerPlugin) {\n  throw new Error('CustomEase requires gsap core; load gsap first');\n}\ngsap.registerPlugin(CustomEase);","typeGuard":"function gsapCoreReady() {\n  return typeof gsap !== 'undefined' && typeof gsap.registerPlugin === 'function';\n}","tryCatchPattern":null,"preventionTips":["Load/import gsap core before CustomEase","Call registerPlugin(CustomEase) before creating eases","Check script tag order in HTML","Single gsap version across the bundle"],"tags":["gsap","plugin-registration","customease"],"backgroundTag":"gsap-plugin-not-registered","analyzedSha":"13e2b790546426a1a2e0e9b409f3f8dc6d6611f2","analyzedAt":"2026-08-29T08:34:05.027Z","schemaVersion":2},"datasetVersion":"2026-08-29T12:17:43.993Z"}