Skip to content

Conversation

@ashphy
Copy link
Owner

@ashphy ashphy commented Sep 15, 2025

Fixes #99

@ashphy ashphy force-pushed the ashphy/issue99 branch 3 times, most recently from 6d6fb22 to b6e7192 Compare September 15, 2025 14:52
@ashphy ashphy marked this pull request as ready for review September 15, 2025 14:58
@ashphy ashphy requested a review from Copilot September 15, 2025 14:59
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds support for JSON with comments (JSONC) by replacing the native JSON.parse() with the jsonc-parser library. This allows the application to handle JSON files that contain comments, which are normally invalid in standard JSON.

  • Replaces JSON.parse() calls with jsonc-parser's parse() function
  • Configures Monaco editor to allow comments and ignore trailing commas in JSON
  • Adds jsonc-parser dependency to handle JSON with comments

Reviewed Changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
src/hooks/use-jsonpath.ts Replaces JSON.parse with jsonc-parser's parse function for session loading and document parsing
src/components/editor/json-editor.tsx Configures Monaco editor to allow comments and trailing commas in JSON
package.json Adds jsonc-parser dependency

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@ashphy ashphy merged commit 458e51b into master Sep 15, 2025
4 checks passed
@ashphy ashphy deleted the ashphy/issue99 branch September 15, 2025 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ignore json with comment

2 participants