Coder Social home page Coder Social logo

The target element was not found. about valine HOT 4 CLOSED

xcss avatar xcss commented on May 18, 2024
The target element was not found.

from valine.

Comments (4)

codefine avatar codefine commented on May 18, 2024 1

已解决。
检查了一遍逻辑,我在valine.swig里面把page.comments的判断加上就好了。

from valine.

xiaweiss avatar xiaweiss commented on May 18, 2024

我配置了之后,不显示数量,也报这个错。请问具体怎么加?主题配置文件里 并没有这个变量 page.comments

from valine.

codefine avatar codefine commented on May 18, 2024

@xiaweiss 评论数量只在评论区显示,在主页和文章页页头区域本来就不显示,估计是没有这个功能。
关于这个报错的解决方法:
打开文件themes/next/layout/_third-party/comments/valine.swig。
第1行{% if theme.valine.enable and theme.valine.appid and theme.valine.appkey %}添加page.comments判断条件,改为{% if page.comments and theme.valine.enable and theme.valine.appid and theme.valine.appkey %}
第4行,插件版本更新为1.1.6。

from valine.

xCss avatar xCss commented on May 18, 2024

@codefine next主题中首页报The target element was not found.是我判断不严谨造成的。后面会提交pr修复。感谢反馈
@xiaweiss 针对首页评论数量的展示,目前正在寻找解决方案,如果解决了会及时通知大家的~

感谢关注。

from valine.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.