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

Link to DevGuide in markbind.org #1161

Open
le0tan opened this issue Mar 29, 2020 · 16 comments
Open

Link to DevGuide in markbind.org #1161

le0tan opened this issue Mar 29, 2020 · 16 comments

Comments

@le0tan
Copy link
Contributor

le0tan commented Mar 29, 2020

Is your request related to a problem?

Currently we have no easy access to the developer's guide from markbind.org. It would be better if developer's guide along with contribution guide can be easily accessible from the official website.

@nbriannl
Copy link
Contributor

Curious, why are we able to see those links in netifly previews but not in the actual site?

@Tejas2805
Copy link
Contributor

I thought this was intentional as it was meant for the users.

@nbriannl
Copy link
Contributor

nbriannl commented Apr 1, 2020

Anyways, I feel that we should make the dev guide visible to users visiting the official website. I am interested to know we have it the way now. @marvinchin Open source projects like https://www.gatsbyjs.org/ have their contributing section visible.

@nbriannl nbriannl added the s.UnderDiscussion The team will evaluate this issue to decide whether it is worth adding label Apr 1, 2020
@Tejas2805
Copy link
Contributor

Tejas2805 commented Apr 12, 2020

Figured it. This is because we are using site.json for Netlify previews. Whereas for the markbind.org we use ug-site.json. This is why the difference.

This is what I think. Let me know your thoughts on it.

@Tejas2805
Copy link
Contributor

site.json for markbind.org

"glob": ["**/*.mbd", "*.md", "userGuide/*.md"]

site.json for our previews

"glob": ["**/*.mbd", "*.md", "userGuide/*.md", "devGuide/*.md", "devGuide/*/*.md"]

@le0tan
Copy link
Contributor Author

le0tan commented Apr 16, 2020

I think @Tejas2805 has found the problem, it's in this file https://github.com/MarkBind/markbind/blob/master/docs/ug-site.json

I support @nbriannl on the idea of making the dev guide publicly visible for similar reasons.

@damithc
Copy link
Contributor

damithc commented Apr 16, 2020

It is fine to give the DG link in public.
Keep in mind the UG should follow the latest released version while DG should follow the master branch.

@Tejas2805
Copy link
Contributor

Can someone guide me on where to find _markbind for the latest release (markbind.org site)? Can't seem to find it. Will accordingly make the PR then.

@Tejas2805
Copy link
Contributor

Can someone guide me on where to find _markbind for the latest release (markbind.org site)? Can't seem to find it. Will accordingly make the PR then.

Think just adding the pages should be enough. Since all headers use it.

@damithc
Copy link
Contributor

damithc commented Apr 19, 2020

Can someone guide me on where to find _markbind for the latest release (markbind.org site)? Can't seem to find it. Will accordingly make the PR then.

This one?
https://github.com/MarkBind/markbind/tree/master/docs

@nbriannl
Copy link
Contributor

nbriannl commented Apr 19, 2020

Hi, sorry for checking in late.

The UG is hosted in https://github.com/MarkBind/markbind.github.io
And DG is hosted in https://github.com/MarkBind/devdocs

The UG is rebuilt every site release, and the DG is rebuilt every commit.

To solve this issue, you could update the Navbar and SiteNav of the UG to contain links and point to the DG

And vice versa, update the Navbar and SiteNav of the DG to include links and point to the UG

Edit: Looking at the structure abit more.

@damithc
Copy link
Contributor

damithc commented Apr 19, 2020

Hi, sorry for checking in late.

The UG is hosted in https://github.com/MarkBind/markbind.github.io
And DG is hosted in https://github.com/MarkBind/devdocs

The UG is rebuilt every site release, and the DG is rebuilt every commit.

To solve this issue, you could update the Navbar and SiteNav of the UG to contain links and point to the DG

And vice versa, update the Navbar and SiteNav of the DG to include links and point to the UG

Edit: Looking at the structure abit more.

Sounds good, if that is indeed the case.

@nbriannl
Copy link
Contributor

Ah, I noticed what stopped the respective links to show was filter tags.

@damithc
Copy link
Contributor

damithc commented Apr 19, 2020

Ah, I noticed what stopped the respective links to show was filter tags.

Sounds right. After all, we should be using our own cool features :-)

@Tejas2805
Copy link
Contributor

Ah, I noticed what stopped the respective links to show was filter tags.

Ya, I noticed this too right now.

@nbriannl
Copy link
Contributor

nbriannl commented Apr 19, 2020

Ok. I did some investigation.

To bring everyone back on track,

Netifly preview:

  • Uses site.json, filter tag set to ["environment--ug", "environment--dg"]

UG:

DG:

The filter tags is the reason why in the NavBar you don't see Dev Guide when in the UG and you don't see User Guide when in the DG.


So it seems the changes includes

  • Tweaking the filter tags accordingly.
  • Making sure the docs are using the correct header.md, which is determined by the layout: in the <frontmatter>

e.g.

<frontmatter>
  title: "Developer Guide"
  layout: devGuide
  pageNav: default
</frontmatter>

or

<frontmatter>
  title: "User Guide - {{ title }}"
  layout: userGuide
</frontmatter>
  • Making sure the link in the header.md is point to the correct url.

i.e.

    <div tags="environment--ug"><li><a href="{{baseUrl}}/userGuide/index.html" class="nav-link">USER GUIDE</a></li></div>
    <div tags="environment--dg"><li><a href="{{baseUrl}}/devGuide/index.html" class="nav-link">DEVELOPER GUIDE</a></li></div>
  • This point has to be handled properly because the baseUrls of the UG and DG, and netifly previews are different.

It would help if someone checked on my suggestion as well.

@le0tan le0tan self-assigned this Oct 9, 2020
@tlylt tlylt unassigned le0tan Aug 3, 2022
@kaixin-hc kaixin-hc added p.Medium and removed s.UnderDiscussion The team will evaluate this issue to decide whether it is worth adding labels Apr 15, 2024
@LamJiuFong LamJiuFong self-assigned this Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants