Describe the bug
An exception is thrown when using square brackets to access properties at the root of an object.
Code sample
const data = {
"@id": "test"
}
JSONPath({json: data, path: "$['@id']", wrap: false});
Console error or logs
TypeError: Unknown value type
Expected behavior
I should be able to select attributes at the root of an object that start with special characters such as "@id"
Expected result
In the example above I expect to get "test" as a result
Environment (IMPORTANT)
"jsonpath-plus": "^10.4.0",
Desktop**
- Windows
- Chrome 145.0.7632.118
Extra Info
This works when accessing a nested object (For example, "$.foo['@id']")