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. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ 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.


  <div id='root'></div>


                body {
    background-color: #6a7b8d;
  font-family: Roboto, sans-serif;
.container {
  display: grid;
  grid-template-columns: 50% 50%;
  margin-top: 3em;
  grid-gap: 1.5em;


 width: 40vw;
 height: 80vh;
  border: 1px solid white;
      box-shadow: 0 0 6px 2px #555;

.right {
  width: 45vw;
    height: 80vh;
    border: 1px solid black;
  overflow: auto;
      box-shadow: 0 0 6px 2px #555;
.right::-webkit-scrollbar {
  width: 3px;
.right::-webkit-scrollbar-track {
  background: #ddd;
.right::-webkit-scrollbar-thumb {
  background: #aaa;

#editor {
width: 100%;
height: 100%;
 padding: 1em;
    background-color: #272d33;
  color: #f7f7f7;
#editor::-webkit-scrollbar {
  width: 3px;
#editor::-webkit-scrollbar-track {
  background: #ddd;
#editor::-webkit-scrollbar-thumb {
  background: #aaa;

  padding: 1em;
  background-color: #c3cad1;

#preview img {
  max-width: 150px;
  display: block;
  margin-left: auto;
  margin-right: auto;


                const initialMarkdown = `
### **Welcome to the Markdown Previewer of the Day!**

**Text Decoration Types:**
***Bold & Italic***

# h1 Header
## h2 Sub-header 
### h3 Sub-Header

**A list item:**

- Sheets
- Pillows
- Duvets

**A link:** [Visit FCC My Site](

**Block Quote of the Day:** 
> "Everybody has to be somewhere!" *Stan Laurel* 

**Inline code looks like this:** \`<body></body>\`

**This is a block of code:** 
var x, y;
x = 5 + 6;
y = x * 10;

**Image of the Day:**
![FCC style="width: 70px;"](

var renderer = new marked.Renderer() = function(href, title, text) {
  return `<a href=${href} target="_blank">${text}</a>`
  breaks: true

class App extends React.Component {
  constructor(props) {
    this.state = {
      markdown: initialMarkdown
  handleChange = e => this.setState({ markdown: })
  render() {
    return (
    <h1 className="text-center my-4 pb-4 align-middle shadow">FCC Markdown Previewer</h1>
        <div className='container'>
        <div className='left'>
          <textarea id="editor" value={this.state.markdown} onChange={this.handleChange} />
          <div className="right">
            <div id="preview" dangerouslySetInnerHTML={{__html: marked(this.state.markdown)}} />

ReactDOM.render(<App/>, document.getElementById("root"))