We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 490d3b3 commit 2dab407Copy full SHA for 2dab407
_app/client.js
@@ -1,6 +1,7 @@
1
const choo = require('choo')
2
const app = choo()
3
4
+app.use(require('./stores/home'))
5
app.route('/', require('./pages/home'))
6
7
// Support for Server-Side Rendering
_app/stores/home.js
@@ -0,0 +1,8 @@
+module.exports = function (state, emitter) {
+ state.title = ''
+
+ emitter.on('update', function({ value }) {
+ state.title = value
+ emitter.emit('render')
+ })
8
+}
0 commit comments