Update Metalsmith and layout plugin

This commit is contained in:
Tim Schaub
2015-11-01 02:18:09 -07:00
parent 85264111cd
commit 0149924551
136 changed files with 138 additions and 138 deletions

View File

@@ -2,7 +2,7 @@ var path = require('path');
var Metalsmith = require('metalsmith');
var handlebars = require('handlebars');
var templates = require('metalsmith-templates');
var templates = require('metalsmith-layouts');
var marked = require('marked');
var pkg = require('../package.json');
@@ -72,7 +72,7 @@ function augmentExamples(files, metalsmith, done) {
var file = files[filename];
var match = filename.match(markupRegEx);
if (match && filename !== 'index.html') {
if (!file.template) {
if (!file.layout) {
throw new Error(filename + ': Missing template in YAML front-matter');
}
var id = match[1];