Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
es6 proxy overview
Search
Joe Wang
April 26, 2018
Programming
1
61
es6 proxy overview
Joe Wang
April 26, 2018
Tweet
Share
More Decks by Joe Wang
See All by Joe Wang
fastbuild-前端资源打包平台架构与设计及其他
nodew
0
210
An Introduction to Reactive Programming based on RxJS
nodew
0
51
Lazy List With Generator and Iterator
nodew
1
720
ddd.pdf
nodew
0
200
An Introduction to Haskell
nodew
2
85
Other Decks in Programming
See All in Programming
【CA.ai #3】Google ADKを活用したAI Agent開発と運用知見
harappa80
0
300
【Streamlit x Snowflake】データ基盤からアプリ開発・AI活用まで、すべてをSnowflake内で実現
ayumu_yamaguchi
1
120
著者と進める!『AIと個人開発したくなったらまずCursorで要件定義だ!』
yasunacoffee
0
130
実はマルチモーダルだった。ブラウザの組み込みAI🧠でWebの未来を感じてみよう #jsfes #gemini
n0bisuke2
1
780
Rubyで鍛える仕組み化プロヂュース力
muryoimpl
0
100
AIエンジニアリングのご紹介 / Introduction to AI Engineering
rkaga
6
2.1k
LLMで複雑な検索条件アセットから脱却する!! 生成的検索インタフェースの設計論
po3rin
2
700
認証・認可の基本を学ぼう後編
kouyuume
0
190
WebRTC、 綺麗に見るか滑らかに見るか
sublimer
1
160
Navigation 3: 적응형 UI를 위한 앱 탐색
fornewid
1
320
Microservices rules: What good looks like
cer
PRO
0
1.3k
FluorTracer / RayTracingCamp11
kugimasa
0
230
Featured
See All Featured
The Invisible Side of Design
smashingmag
302
51k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.5k
Scaling GitHub
holman
464
140k
Rebuilding a faster, lazier Slack
samanthasiow
84
9.3k
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.4k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.5k
It's Worth the Effort
3n
187
29k
Learning to Love Humans: Emotional Interface Design
aarron
274
41k
Building Applications with DynamoDB
mza
96
6.8k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Rails Girls Zürich Keynote
gr2m
95
14k
Done Done
chrislema
186
16k
Transcript
ES6 PROXY AN INTRODUCTION TO
OVERVIEW 1、WHAT IS PROXY 2、USE CASES 3、OBSERVABLE & IMMER.JS 4、DISCUSS
WHAT IS PROXY PROXY IS A DESIGN PATTERN
WHAT IS PROXY PROXY IN JAVASCRIPT The Proxy object is
used to define custom behavior for fundamental operations (e.g. property lookup, assignment, enumeration, function invocation, etc)
WHAT IS PROXY PROXY IN JAVASCRIPT handler.apply() handler.construct() handler.defineProperty() handler.deleteProperty()
handler.get() handler.getOwnPropertyDescriptor () handler.getPrototypeOf() handler.has() handler.isExtensible() handler.ownKeys() handler.preventExtensions() handler.set() handler.setPrototypeOf()
USE CASES BASIC USAGE
USE CASES SET DEFAULT PROPERTIES
USE CASES PRIVATE PROPS
USE CASES TRACK PROPS CHANGE
USE CASES SINGLETON
USE CASES PROP VALIDATORS
USE CASES COOKIE OBJECT HANDLER
USE CASES REVOCABLE PROXY
REAL WORLD PROJECT OBSERVABLE-UTIL ▸ https://github.com/nx-js/observer-util
REAL WORLD PROJECT OBSERVABLE-UTIL
REAL WORLD PROJECT IMMER ▸ https://github.com/mweststrate/immer
REAL WORLD PROJECT IMMER
SUMMARY PROS & CONS ▸ Expando property access ▸ Low
coupling ▸ Protect the original object ▸ Meta programming in a way ▸ Browser compatibility