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

fix: addition of Prev/Next buttons in build time #1273

Merged
merged 10 commits into from
Feb 13, 2023

Conversation

akshatnema
Copy link
Member

@akshatnema akshatnema commented Jan 30, 2023

Description

This PR rewrites the logic of automation of Prev and UpNext buttons of docs in scripts folder. Hence, the entire implementation of the buttons are written and executed on build time, rather on run time, thus improving the efficiency of the website. Also, to inform that the structure of the posts.json has been changed from array of all posts to the JSON object having key-value pairs of docs, blog, about, jobs and docsTree.

Related issue(s)
Extends #1188

Signed-off-by: akshatnema <20bcs022@iiitdmj.ac.in>
Signed-off-by: akshatnema <20bcs022@iiitdmj.ac.in>
@netlify
Copy link

netlify bot commented Jan 30, 2023

Deploy Preview for asyncapi-website ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 8b6e187
🔍 Latest deploy log https://app.netlify.com/sites/asyncapi-website/deploys/63e64e268829da0008c8ab56
😎 Deploy Preview https://deploy-preview-1273--asyncapi-website.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Signed-off-by: akshatnema <20bcs022@iiitdmj.ac.in>
Signed-off-by: akshatnema <20bcs022@iiitdmj.ac.in>
@github-actions
Copy link

github-actions bot commented Jan 30, 2023

⚡️ Lighthouse report for the changes in this PR:

Category Score
🔴 Performance 28
🟠 Accessibility 88
🟢 Best practices 100
🟢 SEO 100
🔴 PWA 30

Lighthouse ran on https://deploy-preview-1273--asyncapi-website.netlify.app/

@akshatnema
Copy link
Member Author

@derberg @alequetzalli @magicmatatjahu Kindly review this PR and do point out the errors you find out in the implementation. In case, you don't understand any part of implementation, feel free to ask it.

@quetzalliwrites
Copy link
Member

hmm this feels a little weird.. what do you think @akshatnema? 🙃

Screen Shot 2023-02-01 at 7 06 38 PM

@akshatnema
Copy link
Member Author

hmm this feels a little weird.. what do you think @akshatnema? upside_down_face

Yeah, this feels little weird for everyone, but if we want to show the rootElement titles too, this one has rootElement title and page title same. And I don't want to hardcode the prev/next buttons specially for this case.

Copy link
Member

yeah i hear you, i guess it will be ok 👍

Copy link
Member

@quetzalliwrites quetzalliwrites left a comment

Choose a reason for hiding this comment

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

🚢

Copy link
Member

@magicmatatjahu magicmatatjahu left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Member

@derberg derberg left a comment

Choose a reason for hiding this comment

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

LGTM!!!

in preview all docs are where they should, same blob posts. I also checked RSS feed and it is generated as it should

well done

@@ -16,8 +23,23 @@ const postDirectories = [
[`${basePath}/jobs`, '/jobs'],
]

const addItem = (details) => {
Copy link
Member

Choose a reason for hiding this comment

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

this could be a switch case, but tbh, I don't really care 😄

@akshatnema
Copy link
Member Author

/rtm

@asyncapi-bot asyncapi-bot merged commit cc1e31e into asyncapi:master Feb 13, 2023
@akshatnema akshatnema deleted the posts-fix branch October 30, 2023 09:46
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.

5 participants