threepointone / ratpack

ready. set. go!
197 stars 10 forks source link

idea: render default export #23

Open threepointone opened 7 years ago

threepointone commented 7 years ago

just an idea.

// @ratpack { render: true }
export default <div>hello world</div>

variant

// @ratpack { render: true }
export default function App(){ // or a class, whatevs 
  return <div>hello world</div>
}

or you could choose a component to render

// @ratpack { render: 'MyComp' }
export class MyComp extends React.Component {
  render() {
    return <div>hello world</div>
  }
}