Skip to content

Instantly share code, notes, and snippets.

@aweary
Last active October 21, 2015 05:05
Show Gist options
  • Save aweary/a8a28f73bc4707539dac to your computer and use it in GitHub Desktop.
Save aweary/a8a28f73bc4707539dac to your computer and use it in GitHub Desktop.
microbe.js example
import microbe from 'microbe.js'
const app = microbe(__dirname)
app.route({
path: '/',
method: 'GET',
handler: duplex => duplex.render('index', {content: 'This is content!'})
})
app.on('start', () => {
console.log(`Application started on port ${app.get('port')}`);
})
app.start(3000);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment