Comments (3)
This apparently occurs when the @name
of two components is the same. The URL of each component's docs is generated from the @name
. The ng-repeat
s in the nav bars track by
the component's url
. Thus, generating the dupe errors.
In in ideal world, the name of two components would never be the same (or else they wouldn't work in the same angular app). However, often our devs copy ncdoc templates and forget to change the default name. In that case, a problem like this shouldn't break major functionality of the documentation web site.
Thus, I'm tempted to submit a PR and remove the track by
statement from the ng-repeats
in the main template. I imagine they are there for a reason, however.
from gulp-ngdocs.
I don't think removing the "track by" is an option since it could have a severe impact on performance.
In my opinion, having repeated names should trigger a warning/error during the generation of the docs, so that the dev notices the repeated name and can fix it right away. Would that be acceptable for you?
from gulp-ngdocs.
This is still an issue for me. Anyone else? I don't have dupe @name documentation in my code. Some how, the source files are creating repeat entries in docs-setup.js.
If i take off the id to loop on in the repeater you can see the repeat directives:
I know this isn't the best place to try to fix it, but i've found if you go into index.js and around line 264 add unique filter:
setup.pages = _.uniq(setup.pages, page => page.id);
from gulp-ngdocs.
Related Issues (20)
- Question: How generate documentation about variables $scope HOT 2
- No "script.js" for JavaScript @example HOT 2
- Error on old graceful-fs version
- Continue to generate docs, even with Parse error
- Cannot convert undefined or null to object
- Show README on main page.
- Order the docs.
- Feature request: Custom index template and index file name
- ng-doc not picking comments from code with carriage return as newline
- abandoned? HOT 1
- Call for new maintainers HOT 4
- Run docs local (inlinePartials option) - Cross origin requests error
- Anyway to get the added component support?
- When using sections sections tabs are overlapping section content
- dependency triggers a "security vulnerability warning" HOT 1
- mentation in .ngdoc file
- Security vulnerability found in dependent packages
- Use in gulp 4 is not possible. HOT 1
- Trying to get in touch regarding a security issue
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 gulp-ngdocs.