Coder Social home page Coder Social logo

reflect.Value.Type about hasper HOT 7 CLOSED

dencold avatar dencold commented on July 19, 2024
reflect.Value.Type

from hasper.

Comments (7)

dencold avatar dencold commented on July 19, 2024

Hey @aaronmehar thanks for bringing this to my attention! I haven't seen this in my local build, here is what my output looks like for the same command run:

$ hugo server watch -t hasper
0 draft content
0 future content
41 pages created
19 paginator pages created
1 tags created
0 categories created
in 97 ms
Watching for changes in also-redacted/{content,layouts,static,themes}
Serving pages from memory
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop

I will do some more digging tomorrow when I will have more time.

Could you do me a favor and send me the output of hugo version? That will also help.

Thanks! Glad you are enjoying/using the theme.

from hasper.

aaronmehar avatar aaronmehar commented on July 19, 2024

Running the latest version using brew.

$ hugo version
Hugo Static Site Generator v0.15 BuildDate: 2015-11-26T06:29:07Z

I think its related to the config.toml file, will check and test tomorrow and confirm

from hasper.

dencold avatar dencold commented on July 19, 2024

Okay, great, good to know we are on the same version.

If you wouldn't mind posting your config.toml, that will help me check from my side as well. (feel free to redact where necessary :)

Thanks again for reporting!

from hasper.

dencold avatar dencold commented on July 19, 2024

@aaronmehar I have this figured out. Awhile back I made commit b334fed which enabled share buttons to be user-configurable. Prior to this, you always had every share button at the bottom of the post in detail view, whether you liked it or not.

However, it looks like I've introduced a regression with this change. I'm guessing you don't have a configuration defined for shares in your config.tml. For example, here's what I have in my config.yaml (I prefer the yaml format, but should be analogous to toml)

  shares:
    twitter: true
    facebook: true
    google-plus: false

When you don't have anything defined for shares the code in the the share.html Go template fails:

if index .Site.Params.shares "twitter"

...because there is nothing to index into.

I'll have a fix in place shortly for this. Thanks so much for bringing this to my attention. Big help!!!

from hasper.

dencold avatar dencold commented on July 19, 2024

@aaronmehar this should be fixed for you now. I've updated the logic so that unset sharing config does not produce the zero value errors. You should be able to pull the latest and see the warnings go away.

However, the default state will have sharing disabled. If you'd like to have sharing links appear on posts. Add this to your site configuration (under the params section):

sharing:
  twitter: true
  facebook: true
  google-plus: true
  pinterest: true

Of course, you're free to disable any of those by flipping the boolean to false.

Let me know if you get stuck, or notice anything else!

from hasper.

aaronmehar avatar aaronmehar commented on July 19, 2024

@dencold I pulled down those changes and its working perfectly as expected.. Thank so much for being so responsive and providing such a quick fix!

from hasper.

dencold avatar dencold commented on July 19, 2024

No problem @aaronmehar! Apologies you ran into this in the first place. I wasn't expecting anyone outside of myself to be using this theme as I haven't yet posted it on the hugo site. Thanks for making use of it! Hope it comes in handy ;)

from hasper.

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.