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 CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

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.

              html, body, #root
  height: 100%

  display: flex
  height: 100%
  flex-direction: column
  justify-content: flex-start
  align-items: center
  overflow: auto
  display: flex
  margin-bottom: 16px
  overflow: auto
  padding: 0.8em 1em
  background-color: #74c6ef
  color: #fff
  border-radius: 3px
  cursor: pointer
    margin-left: 0.5rem
              const { Component, PropTypes } = React;
const { withRouter } = ReactRouter;
const {
  MemoryRouter: Router,
} = ReactRouterDOM;

  .module('ngApp', ['ui.router'])
  .component('appNav', {
    template: `
      <nav class="app-nav">
        <a ui-sref="oranges" class="nav-link">Oranges</a>
        <a ui-sref="apples" class="nav-link">Apples</a>

class AngularNav extends Component {
  static propTypes = {
    history: PropTypes.object.isRequired

  componentDidMount () {
      .run(($state) => {
        $state.go = this.handleAngularRoute;
    angular.bootstrap(this.container, ['ngApp']);
  html = `<app-nav></app-nav>`;

  handleAngularRoute = (state, params, options) => {

  render = () => (
      ref={c => this.container = c}
      dangerouslySetInnerHTML={{__html: this.html}}

const App = () => (
    <div className="container">
        <Route path="/oranges" component={() => <span>🍊🍊🍊</span>} />
        <Route path="/apples" component={() => <span>🍎🍎🍎</span>} />

ReactDOM.render(<App/>, document.querySelector('#root'));
Loading ..................