Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
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
51
es6 proxy overview
Joe Wang
April 26, 2018
Tweet
Share
More Decks by Joe Wang
See All by Joe Wang
fastbuild-前端资源打包平台架构与设计及其他
nodew
0
200
An Introduction to Reactive Programming based on RxJS
nodew
0
45
Lazy List With Generator and Iterator
nodew
1
680
ddd.pdf
nodew
0
190
An Introduction to Haskell
nodew
2
71
Other Decks in Programming
See All in Programming
データと事例で振り返るDevin導入の"リアル" / The Realities of Devin Reflected in Data and Case Studies
rkaga
3
2.9k
医療系ソフトウェアのAI駆動開発
koukimiura
1
150
インプロセスQAにおいて大事にしていること / In-process QA Meetup
medley
0
190
AI Coding Agents Enablement in TypeScript
yukukotani
12
2.9k
OpenTelemetryで始めるベンダーフリーなobservability / Vendor-free observability starting with OpenTelemetry
seike460
0
140
生成AI時代のフルスタック開発
kenn
8
1k
20250429 - CNTUG Meetup #67 / DevOps Taiwan Meetup #69 - Deep Dive into Tetragon: Building Runtime Security and Observability with eBPF
tico88612
0
190
ソフトウェア品質特性、意識してますか?AIの真の力を引き出す活用事例 / ai-and-software-quality
minodriven
18
5.4k
最速Green Tea 🍵 Garbage Collector
kuro_kurorrr
1
160
ts-morph実践:型を利用するcodemodのテクニック
ypresto
1
120
Ruby で作る RISC-V CPU エミュレーター / RISC-V CPU emulator made with Ruby
hayaokimura
5
1.2k
Cloudflare Workersで進めるリモートMCP活用
syumai
12
1.7k
Featured
See All Featured
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.2k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
32
5.8k
Automating Front-end Workflow
addyosmani
1370
200k
Building Adaptive Systems
keathley
41
2.5k
Mobile First: as difficult as doing things right
swwweet
223
9.6k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
31
1.2k
The Cult of Friendly URLs
andyhume
78
6.4k
We Have a Design System, Now What?
morganepeng
52
7.6k
The Straight Up "How To Draw Better" Workshop
denniskardys
233
140k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
331
21k
Optimising Largest Contentful Paint
csswizardry
37
3.2k
How STYLIGHT went responsive
nonsquared
100
5.5k
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