cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

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.

Quick-add: + add another resource

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.

Quick-add: + add another resource

Code Indentation


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.

              <script src="https://derbyjs.github.io/derby-standalone/dist/0.6.0-alpha37/derby-standalone.min.js"></script>

<!-- we create a template to use as the body -->
<script type="text/template" id="body">
  <!-- we use the list view and pass in our users -->
  <view is="custom"></view>
  <view is="common"></view>

<script type="text/template" id="custom">
  <div class="custom">
    custom alert:
    <view is="common" extend></view>

<script type="text/template" id="common">
  <div class="common" on-click="click()">
    Clicking on this div alerts!</div>

              body {
  font-family: Helvetica;
  background: #192F41;
  color: white;
  line-height: 1.5em
.common {
  border: 1px solid #F2627C ;
.custom {
  border: 1px solid #157EBF ;
div {
  margin: 5px;
  padding: 5px;
              // https://github.com/derbyjs/derby-standalone
var app = derby.createApp();
// convenience function for loading templates that are defined as <script type="text/template">
var page = app.createPage();

/* Example Code */

app.component("common", Common)
function Common() {}
Common.prototype.init = function() {
  this.model.set("initial", "common initialization")
Common.prototype.click = function() {
  alert("original alert")

// prototypical inheritance so we can extend the Common component
function Custom() {
  Common.apply(this, arguments);
Custom.prototype = Object.create(Common.prototype);

// our custom function to override the click behavior
Custom.prototype.click = function() {
  alert("custom alert");
app.component("custom", Custom)

/* End Example Code */


Loading ..................