Pen Settings



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


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.


                <h1>Responsive Text Mixin</h1>
<div class="texter">Alright, this next test may involve trace amounts of time travel. So, word of advice: If you meet yourself on the testing track, don't make eye contact. Lab boys tell me that'll wipe out time. Entirely. Forward and backward! So do both of yourselves a favor and just let that handsome devil go about his business.</cav9><br><br> <b>-Cave Johnson</b></div>


                body{  font-family: sans-serif;background: linear-gradient(to top, #1E113A, purple); background-repeat: no-repeat; height: 100vh; color: #fff; padding: 2em; overflow-y: hidden; text-shadow: 0 1px 1px #000;}

@function strip-unit($number) {
  @if type-of($number) == 'number' and not unitless($number) {
    @return $number / ($number * 0 + 1);

  @return $number;
// Responsive text mixin
@mixin responsiveText ($minSize: $font-size, $maxSize: 28px, $minWidth: 420px, $maxWidth: 980px) {

$mxS: strip-unit($maxSize);
$mnS: strip-unit($minSize);
$mxW: strip-unit($maxWidth);
$mnW: strip-unit($minWidth);

  font-size: calc( #{$minSize} + (#{$mxS} - #{$mnS}) * (100vw - #{$minWidth}) / (#{$mxW} - #{$mnW}));
  @media screen and (max-width: $minWidth ){
      font-size: $minSize;
  @media screen and (min-width: $maxWidth ){
      font-size: $maxSize;


h1 {
  @include responsiveText(24px, 72px);

.texter {
  @include responsiveText(12px, 50px);
  max-width: 980px;