Skip to content

Instantly share code, notes, and snippets.

@ColinPeyrat
Created May 11, 2023 09:49
Show Gist options
  • Select an option

  • Save ColinPeyrat/dc97bc6fac2b1776ef0f58b87b992c90 to your computer and use it in GitHub Desktop.

Select an option

Save ColinPeyrat/dc97bc6fac2b1776ef0f58b87b992c90 to your computer and use it in GitHub Desktop.
VSCode - GSAP Snippets
{
"gsap.from()": {
"prefix": "gsf",
"body": [
"gsap.from(${1:el}, {${2:vars}, duration: ${3:0.8}, ease: '${4:power3.out}'});"
],
"description": "gsap.from()"
},
"gsap.to()": {
"prefix": "gst",
"body": [
"gsap.to(${1:el}, {${2:vars}, duration: ${3:0.8}, ease: '${4:power3.out}'});"
],
"description": "gsap.to()"
},
"gsap.fromTo()": {
"prefix": "gsft",
"body": [
"gsap.fromTo(${1:el}, {${2:fromVars}}, {${3:toVars}, duration: ${4:0.8}, ease: '${5:power3.out}'});"
],
"description": "gsap.fromTo()"
},
"gsap.set()": {
"prefix": "gss",
"body": ["gsap.set(${1:el}, {${2:vars}});"],
"description": ".set()"
},
"gsap.delayedCall()": {
"prefix": "gsdc",
"body": ["gsap.delayedCall(${1:delay}, ${2:callback});"],
"description": "gsap.delayedCall()"
},
".set()": {
"prefix": ".set",
"body": [".set(${1:el}, {${2:vars}})"],
"description": ".set()"
},
".to()": {
"prefix": ".t",
"body": [
".to(${1:el}, {${2:vars}, duration: ${3:0.8}, ease: '${4:power3.out}'})"
],
"description": ".to()"
},
".from()": {
"prefix": ".f",
"body": [
".from(${1:el}, {${2:vars}, duration: ${3:0.8}, ease: '${4:power3.out}'})"
],
"description": ".from()"
},
".fromTo()": {
"prefix": ".ft",
"body": [
".fromTo(${1:el}, {${2:fromVars}}, {${3:toVars}, duration: ${4:0.8}, ease: '${5:power3.out}'})"
],
"description": ".fromTo()"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment