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.


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.


                <div id="content">
		Quote retriever
	<div id="quote">
		<p id="quote-content">
			<span style="width:100%; display:block; text-align: center; font-size: 200%; color: rgba(20,60,150,0.5);">
		<p id="quote-title"></p>

	<div id="buttons">
		<button id="get-another-quote-button">New quote</button>
		<button id="tweet">Tweet this</button>
		<button id="font">: )</button>


                body {
	font-family: "Open Sans", "Helvetica Neue", sans-serif;
	padding: 1em;

#content {
	display: block;
	margin: 2em auto auto auto;
	padding: auto;
	max-width: 520px;

#quote {
	padding: 1.5em 3em 1em 3em;
	background: lightblue;
	border-radius: 10px;
	margin: 0.8em 0 1em 0;

h1 {
	padding: 0;
	text-align: center;
	color: #80C3E0;
p {
	font-size: 12pt;
	margin: 6pt auto;
#quote-title {
	font-style: italic;
	font-size: 10pt;
	color: rgba(0,0,0,0.5);
	padding-left: 3pt;

#buttons {
	display: block;
	margin: auto auto;
	text-align: center;

button {
	padding: 8px;
	background: white;
	border: solid 1px #80C3E0;
	border-radius: 5px;
	color: #444;
	font-family: "Open Sans", "Helvetica Neue", "Helvetica", "sans-serif";
button:hover {
	background: rgba(128,195,224,0.2);
	cursor: pointer;

button:disabled {
	background: #f0f0f0;
	color: #666;
	cursor: default;
	border-color: #ccc;

button:focus {
	outline: none;


                $(document).ready(function() {

	$('#get-another-quote-button').on('click', function(e) {
		$.ajax( {
			url: '[orderby]=rand&filter[posts_per_page]=1',
			success: function(data) {
				var post = data.shift(); // The data is an array of posts. Grab the first one.
				$('#quote-title').text("— " + post.title);
			cache: false
	$("#tweet").on("click", function() {
		$("#tweet").text("sorry no tweeting");

	$("#font").on("click", function() {
		$("*").css("font-family", "Wingdings");