我在用撇号博客模块显示个人博客文章页面时遇到了困难。我一定是遗漏了什么还是忘了什么?
下面是如何复制这个问题的方法(使用下面的repo:https://github.com/newdesignideas/sample-veebidisainer中的代码)
我的app.js如下:
var apos = require('apostrophe')({
shortName: 'veebidisainer',
title: 'veebidisainer',
// declaring the blog bundle
bundles: [ 'apostrophe-blog' ],
// These are the modules we want to bring into the project.
modules: {
// This configures the apostrophe-users module to add an admin-level
// group by default
'apostrophe-users': {
groups: [
{
title: 'guest',
permissions: [ ]
},
{
title: 'admin',
permissions: [ 'admin' ]
}
]
},
// This configures the apostrophe-assets module to push a 'site.less'
// stylesheet by default
'apostrophe-assets': {
stylesheets: [
{
name: 'site'
}
],
scripts: [
{
name: 'mo',
}
]
},
// Add your modules and their respective configuration here!
'apostrophe-blog': {
widget: true
},
'apostrophe-blog-pages': {},
'apostrophe-blog-widgets': {},
'apostrophe-pages': {
// We must list 'apostrophe-blog-pages'
types: [
{ name: 'apostrophe-blog-pages',
label: 'Blog'
},
{
name: 'default',
label: 'Default'
},
{
name: 'home',
label: 'Home'
}
]
},
'b2b-main-menu': {},
'b2b-main-menu-widgets': {
extend: 'apostrophe-pieces-widgets'
},
}
});
我检查了MongoDB数据库,并正确地发布了示例测试文章。也许我错过了一个视图文件?因为几乎没有文档--我已经尝试过在适当的地方创建视图文件。这个屏幕截图显示了当前的文件结构:
发布于 2017-02-28 13:11:15
博客文章本身的URL相对于博客页面URL。因此,如果您在/blog
有一个博客页面,并且有一个带有test
片段的测试文章,那么您应该能够在/blog/test
上看到它。
https://stackoverflow.com/questions/42480701
复制相似问题