Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div id="stage">
  <h3>repeat</h3>
  <svg class="logo repeat" version="1.0"       xmlns="http://www.w3.org/2000/svg"
   viewBox="0 0 900 276"
   preserveAspectRatio="xMidYMid meet">

  <g transform="translate(0.000000,276.000000) scale(0.100000,-0.100000)"
  fill="#ffffff" stroke="none">
  <path d="M323 2235 c-12 -9 -14 -102 -11 -592 3 -537 4 -582 20 -600 10 -11
  18 -24 18 -30 0 -18 68 -81 112 -102 39 -20 57 -22 193 -19 l150 3 3 99 c2 64
  -1 103 -9 112 -8 10 -36 14 -98 14 -54 0 -94 5 -104 13 -16 11 -17 59 -19 557
  l-3 545 -119 5 c-74 3 -124 1 -133 -5z"/>
  <path d="M3305 2228 c-3 -7 -6 -94 -7 -193 l-3 -180 -175 -6 c-114 -4 -188
  -11 -211 -20 -81 -32 -142 -100 -167 -185 -19 -65 -16 -501 3 -569 20 -67 81
  -138 142 -165 44 -19 63 -20 367 -18 l321 3 0 670 0 670 -133 3 c-100 2 -134
  -1 -137 -10z m-10 -863 l0 -240 -129 -3 c-178 -4 -166 -21 -166 237 0 269 -11
  252 163 249 l132 -3 0 -240z"/>
  <path d="M8225 2228 c-3 -7 -6 -94 -7 -193 l-3 -180 -170 -5 c-209 -7 -240
  -16 -315 -90 -78 -78 -90 -130 -90 -401 0 -229 12 -296 64 -364 39 -51 51 -60
  105 -85 39 -18 65 -20 261 -20 196 0 222 2 261 20 62 28 83 47 118 108 l31 53
  0 584 0 585 -125 0 c-91 0 -127 -3 -130 -12z m-7 -850 c2 -196 0 -228 -14
  -242 -12 -13 -39 -16 -130 -16 -64 0 -124 5 -135 10 -18 10 -19 23 -19 226 0
  131 4 223 11 235 9 18 20 19 147 17 l137 -3 3 -227z"/>
  <path d="M871 1836 c-9 -11 -11 -103 -8 -373 4 -388 4 -393 62 -469 37 -49 49
  -59 104 -84 39 -18 65 -20 263 -20 211 0 220 1 266 24 51 26 96 71 127 126 19
  33 20 55 20 420 l0 385 -130 0 -130 0 -5 -353 c-4 -299 -7 -354 -20 -362 -25
  -16 -243 -12 -266 4 -18 14 -19 33 -24 363 l-5 348 -121 3 c-96 2 -124 0 -133
  -12z"/>
  <path d="M2010 1843 c-44 -17 -117 -57 -130 -72 -81 -92 -85 -116 -85 -526 l0
  -350 123 -5 c68 -3 130 -1 138 3 12 7 14 64 14 343 0 212 4 342 10 355 10 17
  22 19 140 19 92 0 131 -4 137 -12 4 -7 10 -168 13 -358 l5 -345 131 -3 c100
  -2 133 0 135 10 2 7 2 182 -1 390 l-5 376 -40 58 c-31 46 -53 65 -100 89 l-60
  30 -205 2 c-113 1 -212 -1 -220 -4z"/>
  <path d="M3854 1832 c-95 -31 -154 -93 -181 -192 -16 -60 -17 -483 -1 -548 20
  -82 66 -140 140 -178 47 -24 51 -24 333 -24 l286 0 -3 113 -3 112 -235 5 -234
  5 -13 25 c-17 33 -16 85 0 99 9 7 107 12 293 13 l279 3 3 182 c2 179 2 182
  -24 238 -33 68 -92 120 -165 146 -74 26 -397 27 -475 1z m381 -238 c11 -12 15
  -30 13 -63 l-3 -46 -144 -3 c-97 -2 -148 1 -157 9 -19 15 -18 69 2 97 14 21
  22 22 144 22 105 0 132 -3 145 -16z"/>
  <path d="M4795 1830 c-71 -26 -146 -95 -168 -156 -15 -43 -17 -91 -17 -400 0
  -333 1 -354 21 -398 29 -66 71 -110 134 -140 53 -25 63 -26 219 -26 183 0 196
  -5 196 -72 0 -66 -8 -68 -266 -68 -166 0 -233 -3 -242 -12 -19 -19 -16 -192 3
  -208 11 -9 84 -11 302 -8 l288 4 42 27 c159 102 188 317 61 461 -65 74 -106
  86 -293 86 -173 0 -195 7 -195 65 0 19 4 36 8 39 5 3 89 7 188 9 199 5 230 13
  300 84 66 65 74 102 74 323 0 225 -7 255 -80 327 -67 68 -131 83 -346 82 -146
  -1 -188 -4 -229 -19z m373 -232 c8 -8 12 -58 12 -160 0 -137 -1 -148 -20 -158
  -12 -6 -71 -9 -147 -8 l-128 3 -3 152 c-2 127 0 154 13 167 13 13 40 16 139
  16 81 0 126 -4 134 -12z"/>
  <path d="M5574 1837 c-2 -7 -3 -60 -2 -118 l3 -104 255 0 255 0 3 95 c2 52 0
  105 -3 118 l-5 22 -251 0 c-197 0 -251 -3 -255 -13z"/>
  <path d="M6232 1838 c-13 -13 -17 -183 -6 -212 5 -14 36 -16 240 -16 l234 0
  10 -26 c14 -35 12 -98 -2 -112 -8 -8 -65 -12 -190 -12 -185 0 -199 -3 -263
  -50 -42 -31 -82 -97 -100 -162 -17 -65 -17 -71 0 -140 24 -101 70 -160 154
  -198 42 -19 62 -20 360 -18 l316 3 0 380 0 380 -24 43 c-31 57 -99 112 -164
  134 -43 14 -94 17 -302 17 -183 1 -254 -2 -263 -11z m486 -632 c2 -22 1 -50
  -2 -63 -6 -23 -8 -23 -137 -23 -72 0 -139 5 -150 10 -14 8 -19 21 -19 53 0 24
  6 49 12 55 9 9 52 12 153 10 l140 -3 3 -39z"/>
  <path d="M7280 1839 c-72 -29 -112 -56 -140 -95 -58 -81 -59 -92 -60 -477 0
  -194 0 -358 0 -365 0 -10 30 -12 133 -10 l132 3 2 335 c2 230 6 342 14 357 11
  21 20 23 118 25 l106 3 0 115 0 115 -140 2 c-77 1 -151 -3 -165 -8z"/>
  <path d="M5740 1461 c-94 -11 -171 -66 -212 -150 -33 -68 -30 -207 5 -276 30
  -59 66 -95 125 -124 39 -20 55 -21 235 -19 l192 3 3 92 c4 137 9 133 -157 133
  -153 0 -171 7 -171 66 1 60 12 64 173 64 123 0 146 2 151 16 3 9 6 53 6 99 0
  73 -3 86 -19 95 -21 11 -239 11 -331 1z"/>
  </g>
  
  </svg>
  
  <h3>repeat with pause</h3>
  <svg class="logo repeatWithPause" version="1.0"       xmlns="http://www.w3.org/2000/svg"
   viewBox="0 0 900 276"
   preserveAspectRatio="xMidYMid meet">

  <g transform="translate(0.000000,276.000000) scale(0.100000,-0.100000)"
  fill="#ffffff" stroke="none">
  <path d="M323 2235 c-12 -9 -14 -102 -11 -592 3 -537 4 -582 20 -600 10 -11
  18 -24 18 -30 0 -18 68 -81 112 -102 39 -20 57 -22 193 -19 l150 3 3 99 c2 64
  -1 103 -9 112 -8 10 -36 14 -98 14 -54 0 -94 5 -104 13 -16 11 -17 59 -19 557
  l-3 545 -119 5 c-74 3 -124 1 -133 -5z"/>
  <path d="M3305 2228 c-3 -7 -6 -94 -7 -193 l-3 -180 -175 -6 c-114 -4 -188
  -11 -211 -20 -81 -32 -142 -100 -167 -185 -19 -65 -16 -501 3 -569 20 -67 81
  -138 142 -165 44 -19 63 -20 367 -18 l321 3 0 670 0 670 -133 3 c-100 2 -134
  -1 -137 -10z m-10 -863 l0 -240 -129 -3 c-178 -4 -166 -21 -166 237 0 269 -11
  252 163 249 l132 -3 0 -240z"/>
  <path d="M8225 2228 c-3 -7 -6 -94 -7 -193 l-3 -180 -170 -5 c-209 -7 -240
  -16 -315 -90 -78 -78 -90 -130 -90 -401 0 -229 12 -296 64 -364 39 -51 51 -60
  105 -85 39 -18 65 -20 261 -20 196 0 222 2 261 20 62 28 83 47 118 108 l31 53
  0 584 0 585 -125 0 c-91 0 -127 -3 -130 -12z m-7 -850 c2 -196 0 -228 -14
  -242 -12 -13 -39 -16 -130 -16 -64 0 -124 5 -135 10 -18 10 -19 23 -19 226 0
  131 4 223 11 235 9 18 20 19 147 17 l137 -3 3 -227z"/>
  <path d="M871 1836 c-9 -11 -11 -103 -8 -373 4 -388 4 -393 62 -469 37 -49 49
  -59 104 -84 39 -18 65 -20 263 -20 211 0 220 1 266 24 51 26 96 71 127 126 19
  33 20 55 20 420 l0 385 -130 0 -130 0 -5 -353 c-4 -299 -7 -354 -20 -362 -25
  -16 -243 -12 -266 4 -18 14 -19 33 -24 363 l-5 348 -121 3 c-96 2 -124 0 -133
  -12z"/>
  <path d="M2010 1843 c-44 -17 -117 -57 -130 -72 -81 -92 -85 -116 -85 -526 l0
  -350 123 -5 c68 -3 130 -1 138 3 12 7 14 64 14 343 0 212 4 342 10 355 10 17
  22 19 140 19 92 0 131 -4 137 -12 4 -7 10 -168 13 -358 l5 -345 131 -3 c100
  -2 133 0 135 10 2 7 2 182 -1 390 l-5 376 -40 58 c-31 46 -53 65 -100 89 l-60
  30 -205 2 c-113 1 -212 -1 -220 -4z"/>
  <path d="M3854 1832 c-95 -31 -154 -93 -181 -192 -16 -60 -17 -483 -1 -548 20
  -82 66 -140 140 -178 47 -24 51 -24 333 -24 l286 0 -3 113 -3 112 -235 5 -234
  5 -13 25 c-17 33 -16 85 0 99 9 7 107 12 293 13 l279 3 3 182 c2 179 2 182
  -24 238 -33 68 -92 120 -165 146 -74 26 -397 27 -475 1z m381 -238 c11 -12 15
  -30 13 -63 l-3 -46 -144 -3 c-97 -2 -148 1 -157 9 -19 15 -18 69 2 97 14 21
  22 22 144 22 105 0 132 -3 145 -16z"/>
  <path d="M4795 1830 c-71 -26 -146 -95 -168 -156 -15 -43 -17 -91 -17 -400 0
  -333 1 -354 21 -398 29 -66 71 -110 134 -140 53 -25 63 -26 219 -26 183 0 196
  -5 196 -72 0 -66 -8 -68 -266 -68 -166 0 -233 -3 -242 -12 -19 -19 -16 -192 3
  -208 11 -9 84 -11 302 -8 l288 4 42 27 c159 102 188 317 61 461 -65 74 -106
  86 -293 86 -173 0 -195 7 -195 65 0 19 4 36 8 39 5 3 89 7 188 9 199 5 230 13
  300 84 66 65 74 102 74 323 0 225 -7 255 -80 327 -67 68 -131 83 -346 82 -146
  -1 -188 -4 -229 -19z m373 -232 c8 -8 12 -58 12 -160 0 -137 -1 -148 -20 -158
  -12 -6 -71 -9 -147 -8 l-128 3 -3 152 c-2 127 0 154 13 167 13 13 40 16 139
  16 81 0 126 -4 134 -12z"/>
  <path d="M5574 1837 c-2 -7 -3 -60 -2 -118 l3 -104 255 0 255 0 3 95 c2 52 0
  105 -3 118 l-5 22 -251 0 c-197 0 -251 -3 -255 -13z"/>
  <path d="M6232 1838 c-13 -13 -17 -183 -6 -212 5 -14 36 -16 240 -16 l234 0
  10 -26 c14 -35 12 -98 -2 -112 -8 -8 -65 -12 -190 -12 -185 0 -199 -3 -263
  -50 -42 -31 -82 -97 -100 -162 -17 -65 -17 -71 0 -140 24 -101 70 -160 154
  -198 42 -19 62 -20 360 -18 l316 3 0 380 0 380 -24 43 c-31 57 -99 112 -164
  134 -43 14 -94 17 -302 17 -183 1 -254 -2 -263 -11z m486 -632 c2 -22 1 -50
  -2 -63 -6 -23 -8 -23 -137 -23 -72 0 -139 5 -150 10 -14 8 -19 21 -19 53 0 24
  6 49 12 55 9 9 52 12 153 10 l140 -3 3 -39z"/>
  <path d="M7280 1839 c-72 -29 -112 -56 -140 -95 -58 -81 -59 -92 -60 -477 0
  -194 0 -358 0 -365 0 -10 30 -12 133 -10 l132 3 2 335 c2 230 6 342 14 357 11
  21 20 23 118 25 l106 3 0 115 0 115 -140 2 c-77 1 -151 -3 -165 -8z"/>
  <path d="M5740 1461 c-94 -11 -171 -66 -212 -150 -33 -68 -30 -207 5 -276 30
  -59 66 -95 125 -124 39 -20 55 -21 235 -19 l192 3 3 92 c4 137 9 133 -157 133
  -153 0 -171 7 -171 66 1 60 12 64 173 64 123 0 146 2 151 16 3 9 6 53 6 99 0
  73 -3 86 -19 95 -21 11 -239 11 -331 1z"/>
  </g>
  
  </svg>
  
  
</div>

              
            
!

CSS

              
                body {
  background: #333;
  color: #fff;
  font-family: sans-serif;
}
#stage {
  width: 600px;
  height: 400px;
  margin: 20px auto;
  background: #000;
  padding: 20px;
  position: relative;
  overflow: hidden;
  h3 {
    text-align: center;
    margin-top: 50px;
  }
  .logo {
    margin: auto;
    width: 200px;
    display: block;
    height: auto;
    margin-bottom: 80px;
  }
}

.restart {
  position: absolute;
  bottom: 10px;
  left: 10px;
}
              
            
!

JS

              
                var repeat = $('.repeat');
var repeatWithPause = $('.repeatWithPause');

var tl = new TimelineMax({ repeat: -1 })
  .to(repeat, 0.5, { rotation: 180 })
  .to(repeat, 0.5, { rotation: 0 })

var tl2 = new TimelineMax({ repeat: -1 })
  .to(repeatWithPause, 0.5, { rotation: 180 })
  .to(repeatWithPause, 0.5, { rotation: 0 })
  .addPause(1.0);
              
            
!
999px

Console