6
我在某些react-js庫中看到如下所示的一些語法。這是什麼意思,如何可以幫助我在我的代碼?什麼是在React JS之前的這個關鍵字?
const inputAttributes = {
id: 'events-playground',
placeholder: 'Where are you now?',
onChange: ::this.onInputChanged,
onBlur: ::this.onInputBlurred
};
謝謝。
感謝。我可以在我的反應代碼中使用它,還是使用有限制? –
@Amin Mousavi你可以使用Babel等轉譯器...... –