-
Notifications
You must be signed in to change notification settings - Fork 29
Add article to index for rendering. #11
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
Add article to index for rendering. #11
Conversation
WalkthroughAdded two article objects to Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| { | ||
| "articles": [ | ||
| { | ||
| "slug": "sustainable-living-tips", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These values are referring to the wrong article, @john-walter-munene .
Maybe you forgot to push the commit where you replaced the values here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
public/articles/articles-index.json(1 hunks)
🧰 Additional context used
🪛 Biome (2.1.2)
public/articles/articles-index.json
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: expected , but instead found HEAD
Remove HEAD
(parse)
[error] 5-5: expected , but instead found "slug"
Remove "slug"
(parse)
[error] 5-5: expected , but instead found :
Remove :
(parse)
[error] 5-5: expected , but instead found "sustainable-living-tips"
Remove "sustainable-living-tips"
(parse)
[error] 6-6: expected , but instead found :
Remove :
(parse)
[error] 6-6: expected , but instead found "10 Simple Tips for Sustainable Living"
Remove "10 Simple Tips for Sustainable Living"
(parse)
[error] 7-7: expected , but instead found :
Remove :
(parse)
[error] 7-7: expected , but instead found "Emma Green"
Remove "Emma Green"
(parse)
[error] 8-8: expected , but instead found :
Remove :
(parse)
[error] 8-8: expected , but instead found "2024-01-15"
Remove "2024-01-15"
(parse)
[error] 9-9: expected , but instead found :
Remove :
(parse)
[error] 9-9: expected , but instead found "/images/sustainable-living.jpg"
Remove "/images/sustainable-living.jpg"
(parse)
[error] 10-10: expected , but instead found :
Remove :
(parse)
[error] 10-10: expected , but instead found "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
Remove "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
(parse)
[error] 11-11: expected , but instead found :
Remove :
(parse)
[error] 11-11: expected , but instead found false
Remove false
(parse)
[error] 12-12: expected , but instead found }
Remove }
(parse)
[error] 12-12: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 13-20: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 20-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: unexpected character (
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: unexpected character )
(parse)
🔇 Additional comments (1)
public/articles/articles-index.json (1)
5-5: Address previous reviewer's concern about incorrect article values.A prior review flagged that values at this location refer to the wrong article. Confirm this has been resolved in your merge resolution.
| <<<<<<< HEAD | ||
| "slug": "sustainable-living-tips", | ||
| "title": "10 Simple Tips for Sustainable Living", | ||
| "author": "Emma Green", | ||
| "date": "2024-01-15", | ||
| "image": "/images/sustainable-living.jpg", | ||
| "excerpt": "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank.", | ||
| "featured": false | ||
| }, | ||
| { | ||
| "slug": "sustainable-living-tips", | ||
| "title": "10 Simple Tips for Sustainable Living", | ||
| "author": "Emma Green", | ||
| "date": "2024-01-15", | ||
| "image": "/images/sustainable-living.jpg", | ||
| "excerpt": "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank.", | ||
| "featured": true | ||
| ======= | ||
| "slug": "common-treasuries-governance", | ||
| "title": "Common Treasuries and their Governance", | ||
| "author": "Zahnentferner", | ||
| "date": "2025-10-24", | ||
| "image": "/images/governance.jpg", | ||
| "excerpt": "A surgical reflection on how shared treasuries and governance systems inevitably enable power imbalances, deception, and political extraction.", | ||
| "featured": false | ||
| >>>>>>> b0adf3a (Set featured false for Common Treasuries and their Governance) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Resolve unresolved merge conflict before merging.
The file contains unresolved git merge conflict markers that prevent the JSON from being parsed or rendered. The file must be resolved to valid JSON before this PR can be merged.
- <<<<<<< HEAD
- {
- "slug": "sustainable-living-tips",
- "title": "10 Simple Tips for Sustainable Living",
- "author": "Emma Green",
- "date": "2024-01-15",
- "image": "/images/sustainable-living.jpg",
- "excerpt": "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank.",
- "featured": false
- },
- {
- "slug": "sustainable-living-tips",
- "title": "10 Simple Tips for Sustainable Living",
- "author": "Emma Green",
- "date": "2024-01-15",
- "image": "/images/sustainable-living.jpg",
- "excerpt": "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank.",
- "featured": true
- =======
- "slug": "common-treasuries-governance",
- "title": "Common Treasuries and their Governance",
- "author": "Zahnentferner",
- "date": "2025-10-24",
- "image": "/images/governance.jpg",
- "excerpt": "A surgical reflection on how shared treasuries and governance systems inevitably enable power imbalances, deception, and political extraction.",
- "featured": false
- >>>>>>> b0adf3a (Set featured false for Common Treasuries and their Governance)Clarify the intended resolution: should both articles be added (requiring removal of the duplicate sustainable-living-tips slug), or should only one be kept?
Committable suggestion skipped: line range outside the PR's diff.
🧰 Tools
🪛 Biome (2.1.2)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: unexpected character <
(parse)
[error] 4-4: expected , but instead found HEAD
Remove HEAD
(parse)
[error] 5-5: expected , but instead found "slug"
Remove "slug"
(parse)
[error] 5-5: expected , but instead found :
Remove :
(parse)
[error] 5-5: expected , but instead found "sustainable-living-tips"
Remove "sustainable-living-tips"
(parse)
[error] 6-6: expected , but instead found :
Remove :
(parse)
[error] 6-6: expected , but instead found "10 Simple Tips for Sustainable Living"
Remove "10 Simple Tips for Sustainable Living"
(parse)
[error] 7-7: expected , but instead found :
Remove :
(parse)
[error] 7-7: expected , but instead found "Emma Green"
Remove "Emma Green"
(parse)
[error] 8-8: expected , but instead found :
Remove :
(parse)
[error] 8-8: expected , but instead found "2024-01-15"
Remove "2024-01-15"
(parse)
[error] 9-9: expected , but instead found :
Remove :
(parse)
[error] 9-9: expected , but instead found "/images/sustainable-living.jpg"
Remove "/images/sustainable-living.jpg"
(parse)
[error] 10-10: expected , but instead found :
Remove :
(parse)
[error] 10-10: expected , but instead found "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
Remove "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
(parse)
[error] 11-11: expected , but instead found :
Remove :
(parse)
[error] 11-11: expected , but instead found false
Remove false
(parse)
[error] 12-12: expected , but instead found }
Remove }
(parse)
[error] 12-12: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 13-20: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 20-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 21-21: unexpected character =
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 22-22: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 23-23: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 24-24: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 25-25: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 26-26: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 27-27: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-28: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 28-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: unexpected character >
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: unexpected character (
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: String values must be double quoted.
(parse)
[error] 29-29: unexpected character )
(parse)
🤖 Prompt for AI Agents
In public/articles/articles-index.json around lines 4 to 29 there are unresolved
Git conflict markers (<<<<<<<, =======, >>>>>>>) producing invalid JSON; remove
the conflict markers and reconcile the two entries: either keep both articles
(rename one slug to a unique value and ensure commas and array structure are
valid) or keep only the intended entry (remove the duplicate article entirely),
and ensure the "featured" value is set as intended (preserve b0adf3a change if
that was the source of truth). After resolving, validate the file parses as
JSON.
| "slug": "sustainable-living-tips", | ||
| "title": "10 Simple Tips for Sustainable Living", | ||
| "author": "Emma Green", | ||
| "date": "2024-01-15", | ||
| "image": "/images/sustainable-living.jpg", | ||
| "excerpt": "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank.", | ||
| "featured": false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
Duplicate article slug requires resolution.
The slug "sustainable-living-tips" appears twice in the merged result with conflicting featured flags (false and true). Decide whether to keep one entry or intentionally maintain both with different visibility states. If both are intended, consider renaming one to avoid collision.
Also applies to: 14-20
I'll verify the claims in the review comment by examining the actual JSON file.
---
🏁 Script executed:
```shell
#!/bin/bash
# Read and analyze the articles JSON file for duplicate slugs
cat public/articles/articles-index.json | jq '.articles[] | {slug, featured}' 2>/dev/null || cat public/articles/articles-index.json
Length of output: 8015
Resolve merge conflict before addressing duplicate slug issue.
The file contains unresolved merge conflict markers (lines 1-20). The JSON is currently invalid and must be resolved first. Once resolved, the duplicate "sustainable-living-tips" slug issue you flagged is valid—HEAD contains two entries with this slug but conflicting featured flags (false and true). The incoming commit replaces the duplicate with "common-treasuries-governance". Decide whether to accept the incoming change or manually merge to preserve both articles with unique slugs.
🧰 Tools
🪛 Biome (2.1.2)
[error] 5-5: expected , but instead found "slug"
Remove "slug"
(parse)
[error] 5-5: expected , but instead found :
Remove :
(parse)
[error] 5-5: expected , but instead found "sustainable-living-tips"
Remove "sustainable-living-tips"
(parse)
[error] 6-6: expected , but instead found :
Remove :
(parse)
[error] 6-6: expected , but instead found "10 Simple Tips for Sustainable Living"
Remove "10 Simple Tips for Sustainable Living"
(parse)
[error] 7-7: expected , but instead found :
Remove :
(parse)
[error] 7-7: expected , but instead found "Emma Green"
Remove "Emma Green"
(parse)
[error] 8-8: expected , but instead found :
Remove :
(parse)
[error] 8-8: expected , but instead found "2024-01-15"
Remove "2024-01-15"
(parse)
[error] 9-9: expected , but instead found :
Remove :
(parse)
[error] 9-9: expected , but instead found "/images/sustainable-living.jpg"
Remove "/images/sustainable-living.jpg"
(parse)
[error] 10-10: expected , but instead found :
Remove :
(parse)
[error] 10-10: expected , but instead found "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
Remove "Discover practical ways to reduce your environmental footprint and live more sustainably without breaking the bank."
(parse)
[error] 11-11: expected , but instead found :
Remove :
(parse)
[error] 11-11: expected , but instead found false
Remove false
(parse)
Article now available for rendering.
Summary by CodeRabbit