The Wayback Machine - https://web.archive.org/web/20201205113237/https://github.com/github/view_component/issues/505
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

[TRACKING] ViewComponent documentation site #505

Open
joelhawksley opened this issue Oct 15, 2020 · 8 comments
Open

[TRACKING] ViewComponent documentation site #505

joelhawksley opened this issue Oct 15, 2020 · 8 comments

Comments

@joelhawksley
Copy link
Contributor

@joelhawksley joelhawksley commented Oct 15, 2020

Summary

With Rails 6.1 on the horizon, the ViewComponent project will be under increased attention from the public.

This is a great opportunity for us to make the best first impression possible to the Rails community.

Let's level up our README into a documentation website we'll be proud of!

TODO

  • Register domain name (viewcomponent.org)
  • Pick out / design Jekyll template
  • Move docs from README to site
  • Publish site
  • Review site content and plan for any additions
  • Add quick start to README (#512 (review))

Open questions

  • Should we have a logo?
  • What are some documentation sites we might be inspired by?
@joelhawksley joelhawksley changed the title ViewComponent documentation site [TRACKING] ViewComponent documentation site Oct 15, 2020
@jaredcwhite
Copy link
Contributor

@jaredcwhite jaredcwhite commented Oct 15, 2020

A few Ruby/Rails-aligned documentation sites I'll mention:

@joelhawksley
Copy link
Contributor Author

@joelhawksley joelhawksley commented Oct 15, 2020

@jaredcwhite those are all fantastic examples!

I'm really impressed with the Bridgetown site. Would you be up for helping out with this project?

@jaredcwhite
Copy link
Contributor

@jaredcwhite jaredcwhite commented Oct 15, 2020

@joelhawksley Well, if you don't mind using Bridgetown rather than Jekyll, I think it'd be pretty easy to clone the BT site and clear out the content and tweak the design for use here. You should be able to use GH actions to run the build process and deploy on pages here… slightly more inconvenient than using Jekyll directly, but not by a ton. (Bonus: you get Webpack for front-end assets as well that way…) Anyway, I could help out with all that if need be.

@g13ydson
Copy link
Collaborator

@g13ydson g13ydson commented Nov 17, 2020

@joelhawksley I really like how things are organized using the gitbook + github integration. I created a documentation reorganizing some subjects by sessions. So, if it looks good, I can open a PR with the gitbook MD files.
https://g13ydson.gitbook.io/view-component-docs

@pinzonjulian
Copy link

@pinzonjulian pinzonjulian commented Nov 17, 2020

I'm happy to help out writing any guides or docs!

PS: Love the gitbook site @g13ydson !

@joelhawksley
Copy link
Contributor Author

@joelhawksley joelhawksley commented Nov 18, 2020

@g13ydson very cool! Would we still be able to host this on GitHub pages?

@g13ydson
Copy link
Collaborator

@g13ydson g13ydson commented Nov 20, 2020

@joelhawksley with gitbook it is possible, but it takes more work. I decided to create with Jekyll. #529
DEMO: https://g13ydson.github.io/view_component_doc/

@joelhawksley
Copy link
Contributor Author

@joelhawksley joelhawksley commented Dec 2, 2020

In https://www.youtube.com/watch?v=EQoJVFgZXo4, @maxshelley gave our docs a thorough read as a developer new to the project ❤️

Here are some improvements I think we should look into making based on his experience:

  • Add more detail regarding the form_for workaround. I think we can direct folks towards using the _tag helpers for now.
  • Provide a better example application experience than view-component-demo, which is out of date and lacks documentation.
  • Add documentation for the monkey patch.
  • Add a brief explanation for why ViewComponent is faster than partials.
  • Clarify that content is set by passing in a block, and doesn't need to be an argument in the component initializer.
  • Add documentation on how to generate a sidecar folder with the generator.
  • Clarify that render? is for whether the entire component is rendered or not.
  • Find a better way to explain what is accessible from the component template (instance variables and methods on the component object).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
You can’t perform that action at this time.