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

Added docs website #526

Merged
merged 4 commits into from
Sep 9, 2022
Merged

Added docs website #526

merged 4 commits into from
Sep 9, 2022

Conversation

Tragio
Copy link
Contributor

@Tragio Tragio commented Sep 2, 2022

Hi 👋

Following the issue #470 (comment) and #525 this PR will add a docs website using VitePress. Feel free to suggest and make the changes you feel.

I'll leave here a preview URL from my repo: https://muuri-docs.vercel.app/

Thank you 🎉

@niklasramo
Copy link
Collaborator

Thanks @Tragio, looks great from a glance! I'll review this in-depth as soon as possible 💪

@niklasramo
Copy link
Collaborator

niklasramo commented Sep 9, 2022

@Tragio This looks and works very nice on Desktop and Mobile 👍 Only issue I noticed that if you reload a page or navigate directly to a page (except the landing page) a 404 page will be shown and the only way to get the site working again is going to the index page and reloading it. E.g. if you try to go here (https://muuri-docs.vercel.app/guide/what-is-muuri) via the link directly you should see a 404 page. I wonder if this can be fixed somehow in the configuration or is this a bug in VitePress?

Another thing is that I think the landing page (https://muuri-docs.vercel.app/) is repeating the same stuff that's in muuri.dev already. I'd prefer that the "Docs" section would be the index page for the docs, is this possible somehow? So basically this page should be the index page: https://muuri-docs.vercel.app/guide/what-is-muuri.

Lastly, how does one deploy this (and where) if this is in the muuri repo's main branch? I haven't used VitePress so don't know how things should be wired up. I was thinking that maybe it would make sense to create a separate repo for this or maybe an orphan branch in this repo? E.g. if we'd have different repo for the docs we could host it on gh-pages and keep hosting the current muuri.dev website in this repo's gh-pages. I could then point the docs repo to use docs.muuri.dev subdomain. How does this sound like?

P.S. I invited you as a member to Muuri organisation so you can create the docs repo there if you want to ;)

@Tragio
Copy link
Contributor Author

Tragio commented Sep 9, 2022

@niklasramo all should be fixed and changed as you said 🎉

Related to the branch. Having it in the main branch makes it visually easier for people to contribute and see what's being changed. More importantly, you can create docs per branch. For example, now you have the master branch for 0.9.5, you now import the docs to the dev branch and start working on the next version docs. You can deploy multiple versions of the docs to the versions you want. If you put the docs in an isolated branch, it will make it complicated, as you now have the docs-v0, docs-v1, docs-v2, ... branches.

I never used gh-pages but if you want to use Vercel (free) you can simply merge this branch, import the project in the Vercel, configure the build settings and add the docs.muuri.dev and www.docs.muuri.dev to the domain and is live 😄

CleanShot 2022-09-09 at 13 20 35

@niklasramo
Copy link
Collaborator

@Tragio Ah, that sounds simple enough indeed :) I am familiar with Vercel so yeah, can deploy there 👍 Only problem is that I don't have access to Muuri's repo via Vercel as it's owned by Haltu's organisation (which I'm not a member of), but I can of course fork muuri's repo and use that for deploying if I'm understanding things correctly 😄

But yeah, it's fine by me that include the docs in Muuri's repo if that makes it easier to maintain them 👍 Let's move the docs to a separate repo later on if we face unsurmountable issues with this approach.

One last thing I'd ask is to run npm install instead of yarn install as npm is used in Muuri's repo at the moment (there should be no yarn.lock file, but instead package-lock.json should be updated). And if possible, please use exact version references here: https://github.com/haltu/muuri/pull/526/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519R79-R80 (ditch the ^). I think this PR is ready for merging after that 💪

@Tragio
Copy link
Contributor Author

Tragio commented Sep 9, 2022

@niklasramo for me it sounds awesome. I did the last change, let me know if you need any further changes! Really thank you for your kindness and collaboration in improving this product. I hope it also gave you the motivation to keep pushing it further. 🎉

Copy link
Collaborator

@niklasramo niklasramo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the docs, they look awesome 🙏

@niklasramo niklasramo merged commit 9551104 into haltu:master Sep 9, 2022
@niklasramo
Copy link
Collaborator

I'll deploy the docs to docs.muuri.dev a bit later in the weekend.

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

Successfully merging this pull request may close these issues.

2 participants