Explorar el Código

add util/with_layout.js

master
Bing Sun hace 5 años
padre
commit
175bcf5c3a
Firmado por: sunb ID de clave GPG: F7795F8C590626AB
Se han modificado 1 ficheros con 15 adiciones y 0 borrados
  1. +15
    -0
      src/util/with_layout.js

+ 15
- 0
src/util/with_layout.js Ver fichero

@@ -0,0 +1,15 @@
export default config => {
if (typeof config == 'undefined')
config = {}

if (!config.hasOwnProperty('content'))
config = {'content': config}

return {
view: vnode => [
config.prologue,
m('main', config.content),
config.epilogue
]
}
}

Cargando…
Cancelar
Guardar