Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Namespace conflict #729

Closed
Shaitan1805 opened this issue Sep 22, 2016 · 4 comments
Closed

Namespace conflict #729

Shaitan1805 opened this issue Sep 22, 2016 · 4 comments

Comments

@Shaitan1805
Copy link

Hey!

I'm currently working on a pre processor for typescript API documentation.
I want to have a C# section and a typescript section.
Unfortunately there are colliding some C# namespaces with the typescript namespaces in the documentation. So the result is, that if I click on one of these namespaces in C# section it shows the page of typescript.

I try to make a workaround with the attempt to set a "ts." prefix in front of all typescript namespaces.

My problem is now, that I don't want to show this prefix on documentation pages.
My mynamespace.yml has the attribute uid with value ts.mynamespace and name (displayname) mynamespace.
My class has a reference to ts.mynamespace and attribute namespace is set to ts.mynamespace.

It works perfectly in the toc. But all classes in this namespace will show up namespace: ts.mynamespace because I think the docfx doesn't use the displayname of the namespace.

That's what I found in the source code of docfx.

public static ItemViewModel ToItemViewModel(this MetadataItem model)
        {
            if (model == null)
            {
                return null;
            }
            var result = new ItemViewModel
            {
                ...
                NamespaceName = model.NamespaceName,
                ...
            };

Is there a solution for this problem or any suggestions of what I'm forget?

PS: sorry for my bad english, I'm not a native speaker

@vwxyzh
Copy link
Contributor

vwxyzh commented Sep 22, 2016

Looks like a template issue.

@vwxyzh
Copy link
Contributor

vwxyzh commented Sep 23, 2016

@Shaitan1805, can you share your yaml files?

@chenkennt
Copy link
Contributor

@Shaitan1805 if I understand your scenario correctly, this issue: #396 should be able to help.

@Shaitan1805
Copy link
Author

Sorry that I didn't reply for a long time.
I had a little bug in my pre-processor. I fixed it and it works.
Thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants