Giter Site home page Giter Site logo

jbreckmckye / trkl Goto Github PK

View Code? Open in Web Editor NEW
182.0 182.0 5.0 323 KB

Reactive microlibrary with observables and Knockout-style computeds in 383 bytes

License: Apache License 2.0

JavaScript 100.00%
javascript knockout-computeds microlib observable pubsub reactive

trkl's People

Contributors

jbreckmckye avatar seguri avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

trkl's Issues

Is there a reason subscribe callbacks are called in reverse order?

I noticed that the most recent subscribe() callback is fired first when the value changes. This is a bit counter-intuitive compared to events in the browser and other subscription models I've used, which are first-in, first-out.

Could you explain why this decision decision was made? Just trying to wrap my head around things. Thanks again!

just wanted to say

Very clever solved with the read function and the computation tracker :). At first I really wondered, how is he doing this computed thing without directly referencing the dependencies. But when I saw the read function it made click ๐Ÿ‘

How is the stacktrace for errors in subscriber functions, is it good readable?

I am thinking about using your lib for handling ui state. (Already using flyd for application state and i think this could be a dream team)

How to validate values?

Hi, first off, love the conciseness of this library. Nicely done.

Wondering if you have recommendations for how to restrict that valid values for an observable. For instance, let's say I want to restrict an observable to just integers, or to two values, e.g. light or dark for my theme.

I'm guessing this is a common use case, and just wondered if there was an ergonomic way of doing it once for an observable so invalid values are rejected or at least reported.

Thanks!

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.