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

Auto Save

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

              
                <script src="https://cdn.tailwindcss.com"></script>
<script>
  tailwind.config = {
    important: '.tw',
    corePlugins: {
      preflight: false,
    },
  }
</script>

<!-- Bootstrap Component -->
<section>
  <div class="container">
    <div class="px-4 py-5 my-5 text-center">
      <img class="d-block mx-auto mb-4" src="https://getbootstrap.com/docs/5.3/assets/brand/bootstrap-logo.svg" alt="" width="72" height="57">
      <h1 class="display-5 fw-bold text-body-emphasis">Bootstrap centered hero</h1>
      <div class="col-lg-6 mx-auto">
        <p class="lead mb-4">Quickly design and customize responsive mobile-first sites with Bootstrap, the world’s most popular front-end open source toolkit, featuring Sass variables and mixins, responsive grid system, extensive prebuilt components, and powerful JavaScript plugins.</p>
        <div class="d-grid gap-2 d-sm-flex justify-content-sm-center">
          <button type="button" class="btn btn-primary btn-lg px-4 gap-3">Primary button</button>
          <button type="button" class="btn btn-outline-secondary btn-lg px-4">Secondary</button>
        </div>
      </div>
    </div>
  </div>
</section>

<!-- Tailwind Component -->
<section class="tw">
    <div class="mx-auto container py-32 sm:py-48 lg:py-56">
      <div class="hidden sm:mb-8 sm:flex sm:justify-center">
        <div class="relative rounded-full px-3 py-1 text-sm leading-6 text-gray-600 ring-1 ring-gray-900/10 hover:ring-gray-900/20">Announcing our next round of funding. <a href="#" class="font-semibold text-indigo-600"><span aria-hidden="true" class="absolute inset-0"></span>Read more <span aria-hidden="true">→</span></a></div>
      </div>
      <div class="text-center">
        <h1 class="text-4xl font-bold tracking-tight text-gray-900 sm:text-6xl">Tailwind centered hero</h1>
        <p class="mt-6 !mb-4 text-lg leading-8 text-gray-600">Anim aute id magna aliqua ad ad non deserunt sunt. Qui irure qui lorem cupidatat commodo. Elit sunt amet fugiat veniam occaecat fugiat aliqua.</p>
        <div class="mt-10 flex items-center justify-center gap-x-6"><a href="#" class="rounded-md bg-indigo-600 px-3.5 py-2.5 text-sm font-semibold text-white shadow-sm hover:bg-indigo-500 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-indigo-600">Get started</a><a href="#" class="text-sm font-semibold leading-6 text-gray-900">Learn more <span aria-hidden="true">→</span></a></div>
      </div>
    </div>
</section>
              
            
!

CSS

              
                /* ! tailwindcss v3.4.5 | MIT License | Scoped Preflight */
.tw {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  -moz-tab-size: 4;
  tab-size: 4;
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  font-feature-settings: normal;
  font-variation-settings: normal;
  -webkit-tap-highlight-color: transparent;
}

:where(.tw) .container {
  all: revert;
}

:where(.tw) *,
:where(.tw) ::after,
:where(.tw) ::before {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
  border-color: #e5e7eb;
}

:where(.tw) ::after,
:where(.tw) ::before {
  --tw-content: "";
}

:where(.tw) body {
  margin: 0;
  line-height: inherit;
}
:where(.tw) hr {
  height: 0;
  color: inherit;
  border-top-width: 1px;
}
:where(.tw) abbr:where([title]) {
  -webkit-text-decoration: underline dotted;
  text-decoration: underline dotted;
}
:where(.tw) h1,
:where(.tw) h2,
:where(.tw) h3,
:where(.tw) h4,
:where(.tw) h5,
:where(.tw) h6 {
  font-size: inherit;
  font-weight: inherit;
}
:where(.tw) a {
  color: inherit;
  text-decoration: inherit;
}
:where(.tw) b,
:where(.tw) strong {
  font-weight: bolder;
}
:where(.tw) code,
:where(.tw) kbd,
:where(.tw) pre,
:where(.tw) samp {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-feature-settings: normal;
  font-variation-settings: normal;
  font-size: 1em;
}
:where(.tw) small {
  font-size: 80%;
}
:where(.tw) sub,
:where(.tw) sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}
:where(.tw) sub {
  bottom: -0.25em;
}
:where(.tw) sup {
  top: -0.5em;
}
:where(.tw) table {
  text-indent: 0;
  border-color: inherit;
  border-collapse: collapse;
}
:where(.tw) button,
:where(.tw) input,
:where(.tw) optgroup,
:where(.tw) select,
:where(.tw) textarea {
  font-family: inherit;
  font-feature-settings: inherit;
  font-variation-settings: inherit;
  font-size: 100%;
  font-weight: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  color: inherit;
  margin: 0;
  padding: 0;
}
:where(.tw) button,
:where(.tw) select {
  text-transform: none;
}
:where(.tw) button,
:where(.tw) input:where([type="button"]),
:where(.tw) input:where([type="reset"]),
:where(.tw) input:where([type="submit"]) {
  -webkit-appearance: button;
  background-color: transparent;
  background-image: none;
}
:where(.tw) :-moz-focusring {
  outline: auto;
}
:where(.tw) :-moz-ui-invalid {
  box-shadow: none;
}
:where(.tw) progress {
  vertical-align: baseline;
}
:where(.tw) ::-webkit-inner-spin-button,
:where(.tw) ::-webkit-outer-spin-button {
  height: auto;
}
:where(.tw) [type="search"] {
  -webkit-appearance: textfield;
  outline-offset: -2px;
}
:where(.tw) ::-webkit-search-decoration {
  -webkit-appearance: none;
}
:where(.tw) ::-webkit-file-upload-button {
  -webkit-appearance: button;
  font: inherit;
}
:where(.tw) summary {
  display: list-item;
}
:where(.tw) blockquote,
:where(.tw) dd,
:where(.tw) dl,
:where(.tw) figure,
:where(.tw) h1,
:where(.tw) h2,
:where(.tw) h3,
:where(.tw) h4,
:where(.tw) h5,
:where(.tw) h6,
:where(.tw) hr,
:where(.tw) p,
:where(.tw) pre {
  margin: 0;
}
:where(.tw) fieldset {
  margin: 0;
  padding: 0;
}
:where(.tw) legend {
  padding: 0;
}
:where(.tw) menu,
:where(.tw) ol,
:where(.tw) ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
:where(.tw) dialog {
  padding: 0;
}
:where(.tw) textarea {
  resize: vertical;
}
:where(.tw) input::placeholder,
:where(.tw) textarea::placeholder {
  opacity: 1;
  color: #9ca3af;
}
:where(.tw) [role="button"],
:where(.tw) button {
  cursor: pointer;
}
:where(.tw) :disabled {
  cursor: default;
}
:where(.tw) audio,
:where(.tw) canvas,
:where(.tw) embed,
:where(.tw) iframe,
:where(.tw) img,
:where(.tw) object,
:where(.tw) svg,
:where(.tw) video {
  display: block;
  vertical-align: middle;
}
:where(.tw) img,
:where(.tw) video {
  max-width: 100%;
  height: auto;
}
:where(.tw) [hidden] {
  display: none;
}
              
            
!

JS

              
                
              
            
!
999px

Console