All Projects → WebReflection → introspected

WebReflection / introspected

Licence: ISC license
Introspection for serializable arrays and JSON friendly objects.

Programming Languages

HTML
75241 projects
javascript
184084 projects - #8 most used programming language
CSS
56736 projects

Projects that are alternatives of or similar to introspected

SyncedStore
SyncedStore CRDT is an easy-to-use library for building live, collaborative applications that sync automatically.
Stars: ✭ 1,053 (+1304%)
Mutual labels:  reactive-programming
mongo-images
Ever wonder how you can create a full stack reactive application that also saves images? Well look no further! We've got Spring Webflux, Reactive Mongo Streams with GridFS, and Angular5!
Stars: ✭ 12 (-84%)
Mutual labels:  reactive-programming
snmp notifier
A webhook to relay Prometheus alerts as SNMP traps, because sometimes, you have to deal with legacy
Stars: ✭ 33 (-56%)
Mutual labels:  trap
DARK
Dagger 2 + Anko + Rx + Kotlin
Stars: ✭ 27 (-64%)
Mutual labels:  reactive-programming
most-behave
Experimental continuous Behaviors for most.js
Stars: ✭ 32 (-57.33%)
Mutual labels:  reactive-programming
defi
A bunch of utilities that enable accessor-based reactivity for JavaScript objects
Stars: ✭ 48 (-36%)
Mutual labels:  reactive-programming
makinage
Stream Processing Made Easy
Stars: ✭ 31 (-58.67%)
Mutual labels:  reactive-programming
ufw
A minimalist framework for rapid server side applications prototyping in C++ with dependency injection support.
Stars: ✭ 19 (-74.67%)
Mutual labels:  reactive-programming
learnrx-zh-cn
ReactiveX 官方互动式教程中文翻译,原仓库 https://github.com/ReactiveX/learnrx
Stars: ✭ 52 (-30.67%)
Mutual labels:  reactive-programming
cca zoo
Canonical Correlation Analysis Zoo: A collection of Regularized, Deep Learning based, Kernel, and Probabilistic methods in a scikit-learn style framework
Stars: ✭ 103 (+37.33%)
Mutual labels:  deep
defaults-deep
Like `extend` but recursively copies only the missing properties/values to the target object.
Stars: ✭ 26 (-65.33%)
Mutual labels:  deep
IJCAI2018 SSDH
Semantic Structure-based Unsupervised Deep Hashing IJCAI2018
Stars: ✭ 38 (-49.33%)
Mutual labels:  deep
jest-expect-contain-deep
Assert deeply nested values in Jest
Stars: ✭ 68 (-9.33%)
Mutual labels:  deep
Differentia.js
No longer being supported or maintained. A Graph Theory & Data Structure Library for JavaScript.
Stars: ✭ 13 (-82.67%)
Mutual labels:  deep
rl
Reinforcement learning algorithms implemented using Keras and OpenAI Gym
Stars: ✭ 14 (-81.33%)
Mutual labels:  deep
Combine
🐻‍❄️ Combine 을 공부해 봅시다 🐧
Stars: ✭ 24 (-68%)
Mutual labels:  reactive-programming
WhatFilm
Simple iOS app using TMDb API and RxSwift
Stars: ✭ 35 (-53.33%)
Mutual labels:  reactive-programming
springboot-rsocketjwt-example
Example of using JWT with RSocket and Spring Boot
Stars: ✭ 26 (-65.33%)
Mutual labels:  reactive-programming
rxjs-proxify
Turns a Stream of Objects into an Object of Streams
Stars: ✭ 34 (-54.67%)
Mutual labels:  reactive-programming
ReduxSimple
Simple Stupid Redux Store using Reactive Extensions
Stars: ✭ 119 (+58.67%)
Mutual labels:  reactive-programming

Introspected

Build Status Coverage Status donate

Medium presentation post


If you'd like to be notified about any possible change that could happen to a JSON compatible model / data / object / array / structure, including the possibility to retrieve the exact full path of the object that changed and eventually walk through it, you've reached your destination.

const data = Introspected(
  // any object or JSON compatible structure
  // even with nested properties, objects, arrays
  JSON.parse('{}'),
  (root, path) => {
    // the root object that changed
    console.log(root);
    // the path that just changed
    console.log(path);
  }
);

// now try the following in console
data.a.b.c.d.e.f.g = 'whatever';
data.array.value = [1, 2, 3];
data.array.value.push(4);
// see all notifications about all changes 🎉

JSON.stringify(data);
// {"a":{"b":{"c":{"d":{"e":{"f":{"g":"whatever"}}}}}},"array":{"value":[1,2,3,4]}}

API

  • Introspected(objectOrArray[, callback]) create a new Introspected object capable of having infinite depth without ever throwing errors
  • Introspected.observe(objectOrArray, callback) crate a Introspected with a notifier per each change, or set a notifier per each change to an existent Introspected object
  • Introspected.pathValue(objectOrArray, path) walk through an object via a provided path. A path is an Array of properties, it is usually the one received through the notifier whenever a Introspected object is observed.

Compatibility

Any spec compliant ES2015 JavaScript engine.

(that means native WeakMap, Proxy and Symbol.toPrimitive too)

Live test page

Working: NodeJS 6+, Chrome, Safari, GNOME Web, Edge, Firefox, Samsung Internet (Chrome 51)

Not there yet: UC Browser (WebKit 534)

ISC License

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].