Closed myjeshurun closed 6 years ago
@myjeshurun Hi , Thank you for using this plugin . Could you add code as follow ?
https://github.com/iissnan/hexo-theme-next/blob/master/layout/_macro/post.swig#L313
...
</div>
{{ popular_posts() }}
{#####################}
{### END POST BODY ###}
{#####################}
...
Please tell me whether this issue can be solved .
Hello,
thank you for your help. I did as you told me. But an error occurs, here is the msg:
Unhandled rejection TypeError: Cannot read property 'tags' of undefined
at Object.module.exports.getList
(/Users/jeshurun/docs/hexo/node_modules/hexo-related-popular-posts/lib/list-json.js:127:22)
at module.exports
(/Users/jeshurun/docs/hexo/node_modules/hexo-related-popular-posts/lib/helper.js:7:31)
at Object.<anonymous>
(/Users/jeshurun/docs/hexo/node_modules/hexo-related-popular-posts/index.js:170:32)
at wrapper
(/Users/jeshurun/docs/hexo/node_modules/lodash/lodash.js:4968:19)
at Object._ctx.post_template.render (eval at <anonymous>
(/Users/jeshurun/docs/hexo/node_modules/swig/lib/swig.js:498:13),
@myjeshurun I tried this plugin in the hexo-theme-next. hexo-theme-next and Swig seems to be a special case. In the new plug-in version, it have supported to hexo-theme-next. Please update this plugin and add the following code to the template.
$ npm uninstall hexo-related-popular-posts --save
$ npm install hexo-related-popular-posts --save
For example , Add popular_posts( {} , post )
to the following location.
https://github.com/iissnan/hexo-theme-next/blob/master/layout/_macro/post.swig#L313
...
</div>
{{ popular_posts( {} , post ) }}
{#####################}
{### END POST BODY ###}
{#####################}
...
Please tell me whether this issue can be solved .
@myjeshurun Sory , I forget to update npm version. I have updated 2.0.0 to 2.0.1 just before.
yes. I did try. And it works:) Thank you so much! It is a great plugin.
Blessings in Christ,
Jeshurun 我的仆人雅各,我所拣选的耶书崙哪,不要害怕! Don’t be afraid, Jacob my servant; and you, Jeshurun, whom I have chosen.
On Tue, Aug 8, 2017 at 10:58 AM, tea notifications@github.com wrote:
@myjeshurun https://github.com/myjeshurun Sory , I forget to update npm version. I have updated 2.0.0 to 2.0.1 just before.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tea3/hexo-related-popular-posts/issues/4#issuecomment-320982655, or mute the thread https://github.com/notifications/unsubscribe-auth/AVdc3H2-e14VChul2IF2J6sX7-RpUcLwks5sWHejgaJpZM4OvBef .
It seems doesn't work on next themes
@myjeshurun Hi, I just visited your blog and there was not plugin, it doesn't work now?
@swordspoet It works. But I chose another way :)
On Fri, Oct 27, 2017, 08:02 swordspoet notifications@github.com wrote:
@myjeshurun https://github.com/myjeshurun Hi, I just visited your blog and there was not plugin, it doesn't work now?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/tea3/hexo-related-popular-posts/issues/4#issuecomment-339952476, or mute the thread https://github.com/notifications/unsubscribe-auth/AVdc3LVNINdSMzjtcZEBRjZqhzSJeKV5ks5swcZdgaJpZM4OvBef .
@myjeshurun I have followed your steps in next theme, it might miss some information or something else.
And could you please help me to find the right swig file i need to change? Thank you.
Also , if you occur
DTraceProviderBindings.node
error , please see issue#1. https://github.com/tea3/hexo-related-popular-posts/issues/1For BUG
For question
just push question
For feature request
just push feature request
Environment Info
OS version
Node version(
node -v
)Your site
_config.yml
Your theme
_config.yml
Plugin version(
npm ls --depth 0
)