server.js:
import ream from 'ream'
const app = ream({
pageDirectory: 'pages'
})
app.get('/', (req, res) => {
server.js:
import ream from 'ream'
const app = ream({
pageDirectory: 'pages'
})
app.get('/', (req, res) => {
const reapi = require('reapi') | |
reapi({ | |
view: { | |
'/': (req, res) => { | |
res.send | |
} | |
} | |
}) |
tooling react build | |
# resolve tooling-react | |
tooling build | |
# resolve tooling/lib/build | |
tooling dev | |
# resolve tooling/lib/dev | |
module.exports = { | |
template: 'handlebars', | |
templateOptions: { | |
helpers: { | |
raw: function(options) { | |
return options.fn(this) | |
} | |
} | |
}, | |
prompts: { |
a server for serving docs
./source/a.md ./source/b.md
./page/a
or use next.js
const color = 'red' | |
const App = styled.div`{ | |
color: ${color}; | |
}` | |
App.innerHTML = 'hello world' | |
document.body.appendChild(App) |
import Elx, {h} from 'elx' | |
class Button extends Elx { | |
state = { | |
count: 0 | |
} | |
increment = () => { | |
this.set('count', this.state.count + 1) | |
} |
import routerga from 'vue-router-ga' | |
const router = new Router() | |
routerga(router, 'UA-XXXXX-Y') |
title: Hello
space: "with space"
array:
- foo
- bar
obj:
foo:
bar: 123
<div id="#app"></div> | |
<script src="/path/to/docute.js"></script> | |
<script> | |
docute.data.toc | |
/* | |
[ | |
{title: 'head title', children: []} | |
] | |
*/ |