Giter VIP home page Giter VIP logo

Comments (6)

sergeche avatar sergeche commented on August 18, 2024

This didn't work. Not only did I not get the desired menu, but the menu partial broke and non of my pages rendered correctly.

Just checked: everything works fine. The “Rendering the extension "eco" to "html" on "page.html.eco" didn't do anything.” means you have no Eco plugin installed on DocPad.

from docpad-plugin-menu.

maxlinc avatar maxlinc commented on August 18, 2024

I do have eco, because the files all render fine until I change the structure. I'll investigate a bit more. Is there any way to get debug info?

from docpad-plugin-menu.

kasperisager avatar kasperisager commented on August 18, 2024

I'm getting the same behaviour: With multiple children in the same directory, the generateMenu() function seems to silently break.

from docpad-plugin-menu.

maxlinc avatar maxlinc commented on August 18, 2024

@kasperisager wish I could tell you I found what the problem was or a simple workaround, but I ended up switching to the nested folder structure.

from docpad-plugin-menu.

kasperisager avatar kasperisager commented on August 18, 2024

Seems to be a conflict with the cleanurls plugin as far as I can tell.

from docpad-plugin-menu.

kasperisager avatar kasperisager commented on August 18, 2024

Changing this (https://github.com/sergeche/docpad-plugin-menu/blob/master/src/menu.plugin.coffee#L34)...

parts = document.url.replace(/^\//, '').split('/')

...to this...

parts = document.relativeOutPath.replace(/^\//, '').split('/')

...did the trick for me. The URLs are still being output prefixed with .html, but at least it works with cleanurls now.

P.S.: Might you know a better way to go about this, @sergeche?

from docpad-plugin-menu.

Related Issues (9)

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.