Closed nash1111 closed 4 days ago
Latest commit: |
e193e6e
|
Status: | โ Deploy successful! |
Preview URL: | https://c935a4f5.nash1111-tech-blog.pages.dev |
Branch Preview URL: | https://issue-101.nash1111-tech-blog.pages.dev |
โฑ๏ธ Estimated effort to review [1-5] | 3 |
๐งช Relevant tests | No |
๐ Security concerns | No |
โก Key issues to review |
Possible Bug: The rss.tsx file uses synchronous file reading (fs.readFileSync ) which might block the Node.js event loop if the file is large or if the operation is frequent. Consider using asynchronous file reading methods to improve performance. |
Code Duplication: The generateRSS.ts script and the rss.tsx route both handle RSS feed generation but seem to do so separately. It might be beneficial to centralize RSS feed generation to avoid redundancy and potential inconsistencies. | |
Hardcoded Values: The generateRSS.ts script contains hardcoded paths and file names. It would be better to use environment variables or configuration files for such values to make the code more flexible and environment-independent. |
User description
Why
Closes #101
What
PR Type
Enhancement, Tests, Documentation
Description
feed
andgray-matter
.Changes walkthrough ๐
6 files
Footer.tsx
Add RSS icon and link in footer
app/components/Footer.tsx - Added RSS icon and link to the footer.
const.ts
Add site constants for metadata
app/lib/const.ts
and favicon.
root.tsx
Add alternate links for RSS, JSON Feed, and Atom
app/root.tsx - Added alternate links for RSS, JSON Feed, and Atom.
_index.tsx
Use constants for meta tags
app/routes/_index.tsx - Updated meta tags to use constants for site title and author name.
rss.tsx
Create RSS feed route
app/routes/rss.tsx - Created a new route to load and display RSS feed data.
generateRSS.ts
Add script to generate RSS, JSON, and Atom feeds
scripts/generateRSS.ts
2 files
lastUpdated.ts
Update last updated timestamp
public/lastUpdated.ts - Updated the last updated timestamp.
currentIssues.json
Update current issues JSON file
public/currentIssues.json - Updated current issues JSON file.
3 files
commit-feeds.yaml
Add GitHub Action for generating feeds
.github/workflows/commit-feeds.yaml - Added GitHub Action to generate and commit feed files.
commit-issues.yaml
Add GitHub Action for generating current issues JSON
.github/workflows/commit-issues.yaml - Added GitHub Action to generate and commit current issues JSON.
playwright.yaml
Add GitHub Action for Playwright tests
.github/workflows/playwright.yaml
1 files
package.json
Add dependencies for feed generation
package.json - Added dependencies for `feed` and `gray-matter`.
3 files
atom.xml
Add Atom feed file
public/atom.xml - Added Atom feed file.
feed.json
Add JSON feed file
public/feed.json - Added JSON feed file.
rss.xml
Add RSS feed file
public/rss.xml - Added RSS feed file.