Ace: New JSON mode with autocompletion, etc.

Created on 8 Feb 2016  ·  4Comments  ·  Source: ajaxorg/ace

I have nearly completed my reimplementation of JSON mode with:

  1. Support for multiple errors in code (instead of failing after first error)
  2. JSON Schema validation support
  3. Auto-completion support according to a provided JSON Schema
  4. Contributions support: allowing insertion of code based on complex scenarios - for example downloading values from external data source
  5. Custom validation - allowing to provide second level of logical validation of JSON document
    All operations are properly executed in web worker.

I would be happy to share my code, but there are two problems:

  1. Major one: I am utilizing some JSON parsers from a different large project coming with an MIT license. This might be a dealbreaker.
  2. Minor one: I am far too lazy to write tests for trivial code :-(
  3. Would you like to accept such a PR (should I create one)?
  4. How should I handle license headers for such a PR?

BTW. Great job implementing the ACE editor! :)

All 4 comments

That sounds interesting. Please submit a pr or give a link to the repository with the code, and we can decide how to proceed. If it's not possible to include in ace, we can still maintain json tooling in a separate repository. I actually want to move other workers into their own repositories too.

It is currently in my private repository so the action plan:
I will

  1. complete my code (excluding contributions (4) and custom validation (5) mechanism - I will explain below why)
  2. fork ace repo on GH
  3. Move and cleanup code to this forker repo
  4. Create a PR

I am going to

  • keep all third pirty code in modes/json subdir after removing legacy parser. I am going to keep all the original MIT headers in this dir and also add LICENSE to this dir.
  • push only the javascript files with proper simplified common js module stylings (I will not push the original typescript files). I will provide links to the original typescript files for reference in some documentation file.
  • Apply my own modifications to the existing modes/json_worker, modes/json keeping BSD header

Regarding contributions and custom schema validation - I would need to create yet another extensibility kinds (like for modes, themes, etc) for plugable contributions and custom schema validation: this is something requiring more discussion - as for my own private fork I planned hardcoding of those mechanisms. Such plugins should be loadable into worker using standard ACE mechanisms.

Does this all sound reasonable?

Any update on this?Is this feature supported now?

Is this repository still maintained? 👀

Was this page helpful?
0 / 5 - 0 ratings