Code Monkey home page Code Monkey logo

Comments (5)

kevinresol avatar kevinresol commented on August 30, 2024

The library expect users to type it as { foo:Null<String> } because typecrawler has the nullable branch, no?

from tink_json.

back2dos avatar back2dos commented on August 30, 2024

Well, yeah. In this case I just had "unsafe" data that contained a null and the writer simply wrote it out. Not sure how to handle it, but ideally the the error would surface during serialization.

from tink_json.

kevinresol avatar kevinresol commented on August 30, 2024

Wouldn't this be "solved" by enabling null safety?

from tink_json.

back2dos avatar back2dos commented on August 30, 2024

Well, the null came from haxe.Json.parse(something). It might just as well be a database field or something. Perhaps for my case it would be sufficient to run tink_validation over the data, but I still wanna measure what the cost of checking in the writer might be. Maybe it's not even noticeable, otherwise it can be flagged.

from tink_json.

back2dos avatar back2dos commented on August 30, 2024

Hmm. I think in the end it's the user's responsibility to validate the data (via tink_validation or whatever).

from tink_json.

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.