Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ 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

              
                <body>
  
  <container>
    
 <div class="svgLine2 svgLine2-container svg-desktop svgLine2-trigger">
  <svg width="1376" height="7269" viewBox="0 0 1376 7269" xmlns="http://www.w3.org/2000/svg">
<path class="lineTwo" fill="none" stroke-width="1px" d="M1260.5 0.499023C1355 0.499023 1400.79 143.697 1359.5 332.5C1315.84 532.133 1428.33 1152.46 1296.5 1417.5C1066.31 1880.31 624.297 1744.1 605 2050C554 2858.5 1043 2632 1043 3228C1043 3911 306.5 3569.5 108.5 3721.5C-89.5 3873.5 -14.4999 4282.5 335 4282.5C665 4282.5 889.5 4079.5 1092.5 4282.5C1127.83 4366.17 1103.3 4533.5 722.5 4533.5C453 4533.5 315.5 4584.5 369.5 4702.5C409.146 4789.13 696.5 4781.5 981 4781.5C1216.5 4781.5 1352.3 5356.5 799.5 5356.5C280.5 5356.5 123 5559 123 5985.5C123 6689 1309 6146.5 1309 6705C1309 7122 723 6892 723 7169C723 7268 863.422 7268 936 7268" stroke="#E3001A" />
  </svg>
 </div>
    
</container>
  
          <script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.10.4/gsap.min.js"></script>
      <script src="https://assets.codepen.io/16327/DrawSVGPlugin3.min.js"></script>


</body>
              
            
!

CSS

              
                
              
            
!

JS

              
                console.clear();

gsap.registerPlugin(ScrollTrigger, DrawSVGPlugin);

const svgLine2 = gsap.timeline({
    defaults: {
      duration: 1
    },
    scrollTrigger: {
      id: "svgLine2",
      trigger: ".svgLine2-trigger",
      scrub: 1.2,
      start: "top center",
      end: "bottom center",
      markers: true
    }
  })
  .from(".lineTwo", {
    drawSVG: 0
  }, 0)
              
            
!
999px

Console