Pen Settings



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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource


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


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.


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.


                <script src=""></script>
<link rel="stylesheet" href="">

<div id="pagetop"><a href="#top">	<i class="fas fa-arrow-up"></i></a></div>



  text-align: center;
  margin-bottom: 40px;

#pagetop {
    position: fixed;
    right: -80px;
    bottom: 10px;
    margin: 0;
#pagetop a{
    position: relative;
    display: flex;
    width: 60px;
    height: 60px;
    justify-content: center;
    background: #000080;
    transition: opacity .6s ease;
    color: #FFFFFF;
    align-items: center;
    text-decoration: none;
    font-size: 50px;
#pagetop a:hover {
    opacity: .3;
@media screen and (max-width:767px) {
#pagetop a {
    width: 50px;
    height: 50px;


                jQuery(function() {
  var appear = false;
  var pagetop = $('#pagetop');
  $(window).scroll(function () {
   if ($(this).scrollTop() > 100) {  //100pxスクロールしたら
      if (appear == false) {
        appear = true;
          'right': '10px' //右から0pxの位置に
        }, 300); //0.3秒かけて現れる
    } else {
      if (appear) {
        appear = false;
          'right': '-60px' //右から-50pxの位置に
        }, 300); //0.3秒かけて隠れる
  }); () {
    $('body, html').animate({ scrollTop: 0 }, 500); //0.5秒かけてトップへ戻る
    return false;