Object.observe在chrome 50中删除 [英] Object.observe remove in chrome 50

查看:151
本文介绍了Object.observe在chrome 50中删除的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Chrome中发布了一条警告消息,注意到 Object.observe 方法已被弃用,并将于2016年4月左右在Chrome 50中删除。



您有替代解决方案来替换 Object.observe 吗?

谢谢

解决方案

与性能有关的一些问题。请参阅此链接 http://www.infoq.com/news/2015 / 11 / object-observe-withdrawn



我认为你应该看看RxJS库,它是可观察的


使用RxJS,您可以表示多个异步数据流(即
来自不同来源,例如股票报价,tweets,计算机事件,
web服务请求等。),并使用
Observer对象订阅事件流。每当发生事件时,Observable都会通知订阅的Observer
实例。


https://github.com/Reactive-Extensions/RxJS/


I had a warning message in Chrome, this one notice that Object.observe method is deprecated and will be removed in Chrome 50 around April 2016.

Have you an alternative solution to replace Object.observe ?

Thanks

解决方案

So it was depricated and will be removed because of some problem with perfomance. Please see this link http://www.infoq.com/news/2015/11/object-observe-withdrawn

I think you should look into RxJS library and it's Observable

Using RxJS, you can represent multiple asynchronous data streams (that come from diverse sources, e.g., stock quote, tweets, computer events, web service requests, etc.), and subscribe to the event stream using the Observer object. The Observable notifies the subscribed Observer instance whenever an event occurs.

https://github.com/Reactive-Extensions/RxJS/

这篇关于Object.observe在chrome 50中删除的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆