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

[enhancement]: jsonConfig - type "jsonEditor" isn't supporting JSON5 #2947

Open
1 task done
hombach opened this issue Feb 9, 2025 · 4 comments
Open
1 task done

Comments

@hombach
Copy link

hombach commented Feb 9, 2025

No existing issues.

  • There is no existing issue for my request.

Related problems

jsonConfig - type "jsonEditor" isn't supporting JSON5 - would be very helpfull to include some coments with //....
Right now it's working for "String" states, role "text" or "json" but you'll get error messages when using "//" or even keys with out ""

Description

switch code check to JSON5

Additional context

No response

@Apollon77
Copy link
Collaborator

But what then? io-package where config is written mostly does not support json5 either ... so whats the usecase? Also transfer then e.g. in a message would then need to be a string and adapter-side parsing needs to support json5 too?

@hombach
Copy link
Author

hombach commented Feb 10, 2025

Current usecase is a JSON to be used with Apache ECHARTS, by use of flexcharts adapter.

There JSON and JSON5 is working fine. With JSON5 comments are possible, what is much easier for users to adapt the JSON according to own needs. It's also working as it is, but with lots of error messages inside the editor.

@mcm1957
Copy link
Contributor

mcm1957 commented Feb 10, 2025

one remark

If json5 support will be added this should be controlled by an extra option as dev of adapter should enable json5 explicitly after verufying that the targer of the jsonncan handle json5.

@hombach
Copy link
Author

hombach commented Feb 10, 2025

Yes, Martin, absolutely!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants