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.


                <svg viewBox="0 0 100 100" >
    <circle r="48" cx="50" cy="50"/>
    <foreignObject id="text" width="100" height="100">
        <div class="shape shape-left"></div>
        <div class="shape shape-right"></div>
        <div class="text">
            <h1 contenteditable>Flowing text inside a shape</h1>
            <p contenteditable>This technique uses two shapes set as shape-outside to flow text within a shape, mimicking the functionality of the shape-inside property. It's implemented in an SVG foreignObject tag so it's scalable. Edit the text and notice how it stays within its bounds.</p>  


                @import url('//');
@import url('//');

body {
    height: 100vh;
    margin: 0;
    display: flex;
    background: #000 url(;
    background-size: cover;

svg {
    margin: auto;
    width: 50%;
    min-width: 320px;
    max-height: 100%;

svg circle {
    fill: red;
    mix-blend-mode: multiply;

.shape {
    height: 100%;
    width: 50px;
    shape-margin: 2.6px;

.shape-left {
    float: left;
    shape-outside: url(;

.shape-right {
    float: right;
    shape-outside: url(;

.text {
    font-size: 3.9px;
    width: 100px;
    height: 100%;
    text-align: center;
    line-height: 1.6;
    color: white;
    font-family: 'Lato';
    hyphens: auto;
    text-shadow: 0 .2px .3px rgba(0,0,0,.3);

p { 
    margin: 0; 
    text-align: justify;
    text-align-last: center;

h1 {
    font-size: 7px;
    margin-bottom: 5px;
    padding-top: 10px;
    font-family: 'Playfair Display';