Skip to content

Instantly share code, notes, and snippets.

@brianleroux
Created February 2, 2018 22:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brianleroux/4b6dcc75e6bebcb9a3c4a25a3a682c65 to your computer and use it in GitHub Desktop.
Save brianleroux/4b6dcc75e6bebcb9a3c4a25a3a682c65 to your computer and use it in GitHub Desktop.
An arc.codes route handler that uses bootstrap
const arc = require('@architect/functions')
const layout = require('@architect/shared/views/bootstrap')
function route(req, res) {
let html = layout({
title: 'My App',
body: `
<div class=jumbotron>
<h1 class=display-4>Add to Slack</h1>
<p class=lead>Install this app to start using it in Slack.</p>
<hr class=my-4>
<p>${msg}</p>
<p class="lead">TODO REAL BUTTON HEREEEE</p>
</div>`,
})
res({html})
}
exports.handler = arc.html.get(route)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment