소스 검색

Remove scope binding on x-data functions

Simone Todaro 5 년 전
부모
커밋
0374efa15d
3개의 변경된 파일0개의 추가작업 그리고 8개의 파일을 삭제
  1. 0 0
      dist/alpine.js
  2. 0 0
      dist/alpine.js.map
  3. 0 8
      src/component.js

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
dist/alpine.js


파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 0 - 0
dist/alpine.js.map


+ 0 - 8
src/component.js

@@ -15,14 +15,6 @@ export default class Component {
         // Construct a Proxy-based observable. This will be used to handle reactivity.
         this.$data = this.wrapDataInObservable(unobservedData)
 
-        // Walk through the raw data and set the "this" context of any functions
-        // to the observable, so data manipulations are reactive.
-        Object.keys(unobservedData).forEach(key => {
-            if (typeof unobservedData[key] === 'function') {
-                unobservedData[key] = unobservedData[key].bind(this.$data)
-            }
-        })
-
         // After making user-supplied data methods reactive, we can now add
         // our magic properties to the original data for access.
         unobservedData.$el = this.$el

이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.