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

Docs: new site for docs #436

Merged
merged 3 commits into from
Apr 4, 2020
Merged

Docs: new site for docs #436

merged 3 commits into from
Apr 4, 2020

Conversation

anikethsaha
Copy link
Member

@anikethsaha anikethsaha commented Mar 31, 2020

Created a site for the docs using docsify

  • Site preview : https://espree-site.netlify.com/#/

  • Features

    • searching
    • dark mode
    • code highlighting and copy clipboard
    • edit button
    • responsive
    • easy adding of content. (simply add .md file in docs folder and add it to _sidebar.md, that's it)
  • docs about usage, about and developer guide can be added smoothly once the content is ready

  • about the demo page, as this is mostly a static site having demo might be a tricky one as docsify is no-framework static site generator. It can be done but having no framework demo page might be heavy load. I can give it a shot if time permits 👍

  • Screen shots

  • image

  • image

  • image

  • image

  • Side bar in mobile view : image

I couldn't find the logo for espree so I used eslint's logo.
If dark mode is not preferrable, let me know, I will remove the plugin for it

ref #25

PS: it took 8-10 mins (without the deployment step) to create this site. 😁

Copy link
Member

@nzakas nzakas left a comment

Choose a reason for hiding this comment

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

Wow, very cool! Thanks for doing this.

Is it possible for you to add a script that will auto run docsify as part of this PR?

@kaicataldo
Copy link
Member

Wow, I hadn't heard of Docsify before. This is really cool.

Re the demo, I think we should point people to AST Explorer, since it's an existing, well-maintained tool.

@anikethsaha
Copy link
Member Author

Is it possible for you to add a script that will auto run docsify as part of this PR?

@nzakas I didn't get this. Did you mean having no server to run the script like it can be run in file protocol ?

@anikethsaha
Copy link
Member Author

Wow, I hadn't heard of Docsify before. This is really cool.

Re the demo, I think we should point people to AST Explorer, since it's an existing, well-maintained tool.

Yes, this is better, AST Explorer does have a espree parser as a dedicated option.
I will add a link in the navbar

@anikethsaha
Copy link
Member Author

I added a demo link in the sidebar instead of navbar as it was not looking in small browser width as there is the dark mode and github banner there as well.

@kaicataldo, @nzakas
Let me know if you want any changes

@anikethsaha
Copy link
Member Author

https://espree-site.netlify.com/#/

Will have a preview of the live changes 👍

@kaicataldo
Copy link
Member

@nzakas We won’t need a build step because it’s not actually a static site. I believe this works by pointing Netlify to docs/index.html and the site is generated by the docsify script at runtime. I do think we should add docsify-cli as a dependency and to have an npm script for local hosting/development.

@anikethsaha Is this published under your own personal account on Netlify? If so, would you be willing to transfer it to the ESLint organization so that we can maintain it going forward? This would allow us to add a custom domain as well (even if it’s just a subdomain of eslint.org).

Regarding the AST Explorer link, I wonder if we should add this to the home page with an explanation of what AST Explorer is instead? I think having an external link without an explanation will be confusing.

@anikethsaha
Copy link
Member Author

anikethsaha commented Apr 1, 2020

@nzakas We won’t need a build step because it’s not actually a static site. I believe this works by pointing Netlify to docs/index.html and the site is generated by the docsify script at runtime.

yes, everything here is the runtime

I do think we should add docsify-cli as a dependency and to have an npm script for local hosting/development.

@kaicataldo docsify-cli needs to be installed as a global dep. We don't need this in order to host it.
consider docsify as no-framework js script. we actually dont need any build step. for local development, you can use the cli or any other server just to serve the docs folder

@anikethsaha Is this published under your own personal account on Netlify? If so, would you be willing to transfer it to the ESLint organization so that we can maintain it going forward? This would allow us to add a custom domain as well (even if it’s just a subdomain of eslint.org).

yes, it's under my personal account. I can transfer the account or if you want I will delete this site and you can simply point the publish directory in netlify to docs dir and that's it.
let me know which is fine by you 👍

Regarding the AST Explorer link, I wonder if we should add this to the home page with an explanation of what AST Explorer is instead? I think having an external link without an explanation will be confusing.

yes it makes sense, can you share what kind of explanation I need to add cause I think it may be something about the what are ASTs, and how we can get AST in espree ?

@nzakas
Copy link
Member

nzakas commented Apr 3, 2020

Ah okay, I totally misunderstood what was happening here. Thanks for explaining.

I think we should be able to set up our own Netlify site to use this. Maybe we can use espree.eslint.org?

@kaicataldo
Copy link
Member

yes it makes sense, can you share what kind of explanation I need to add cause I think it may be something about the what are ASTs, and how we can get AST in espree ?

We should probably rethink our documentation since it's so incomplete, but I think it makes sense to have a short section about AST Explorer and how it can be used to visualize the AST in the AST section of the docs. As I think about this more, I actually think we should just merge this as-is so that we can get our Netlify site set up and then iterate on it from there.

@kaicataldo
Copy link
Member

One small comment above but otherwise this LGTM.

@anikethsaha anikethsaha requested a review from kaicataldo April 3, 2020 16:01
Copy link
Member

@kaicataldo kaicataldo left a comment

Choose a reason for hiding this comment

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

I think we should merge this as-is and iterate from there. Once we get it merged I can set up the Netlify site.

@kaicataldo
Copy link
Member

Thanks for doing this!

@nzakas
Copy link
Member

nzakas commented Apr 3, 2020

Agreed. Merge + iterate is the way to go.

@anikethsaha
Copy link
Member Author

anikethsaha commented Apr 4, 2020

thanks for the quick review.
Let me know if you need anything over the iteration 👍

@kaicataldo kaicataldo merged commit 9b91bcc into eslint:master Apr 4, 2020
@kaicataldo
Copy link
Member

This site is now live at https://espree.netlify.com.

@anikethsaha anikethsaha deleted the site branch April 5, 2020 06:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants