Comments (6)
The idea of optimize
option is to remove index.html
for you. I don’t quite understand what you’re trying to do.
from docpad-plugin-menu.
I want to include root document (with url of "/") to the menu. When index.html removed - there is no root document in the generated menu. I.e. if we have a site example.com with subfolders dir1 and dir2 which contains some documents, then generated menu will contains example.com/dir1 and example.com/dir2, but not root document - example.com.
from docpad-plugin-menu.
There are number of ways you can do it: explicitly add root item in your templates, create custom function in DocPad config which will extend menu structure, generated by generateMenu
method etc.
from docpad-plugin-menu.
Yep but in those cases I will need to handle "current" state of this item by myself, it will not be really handled by the plugin. Not a big issue really, I just wanted to find some way to include this root item in the set which handled by plugin so everything will just happens automatically...
from docpad-plugin-menu.
+1
would be nice to have this!
from docpad-plugin-menu.
another plus one, id love to not be statically hardcoding my / note into the html of the menu.
from docpad-plugin-menu.
Related Issues (9)
- Support multiple children in one folder HOT 6
- state property doesn't work for index files with optimize = false
- no children with optimize = false
- Incompatible with "cleanurls" plugin HOT 1
- Skipfiles
- Item duplicate HOT 4
- Maximum call stack size exceeded. HOT 5
- Only including a subset of the generated menu structure HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docpad-plugin-menu.