Code Monkey home page Code Monkey logo

Comments (4)

huyl avatar huyl commented on May 18, 2024

@tidoust Thanks a lot!

Any time estimate on fixing "values in nested array
are still lost during reordering for the time being"?
It's a showstopper for me right now.

Thanks!

from jsonform.

tidoust avatar tidoust commented on May 18, 2024

@huyl, hopefully I'll be able to find some time this week to fix the remaining issue.

The main bug to fix lies in the getPreviousNumberOfItems function. It should also receive the current property that the code is interesting in on top of the path that leads to that property. Without that parameter, the function simply returns 0, causing all nested values to disappear.

from jsonform.

huyl avatar huyl commented on May 18, 2024

I've been looking at AngularJS and I think it could be a great framework for implementing jsonform in such a way that the generated values JSON will always be kept in sync.

Check out this demo with sortable drag-n-drop elements in an arbitrarily deep tree:

http://jsfiddle.net/huyz/x8Y2F/3/

Note that the underlying JSON will be kept in sync at all times, which is something that I need for my application (because the generated JSON is actually a form specification which I need to preview in real-time to implement a sort of wysiwig UI)

from jsonform.

tidoust avatar tidoust commented on May 18, 2024

@huyl, closing the issue as I fixed the buggy getPreviousNumberOfItems function in last commit. Nested arrays now seem to work well in the playground. I may have missed some corner case though, let me know if something's still not working as expected.

from jsonform.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.