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
De volta ao Futuro do JS: As próximas features ...
Search
Willian Martins
August 08, 2020
Technology
0
98
De volta ao Futuro do JS: As próximas features e propostas incríveis
Willian Martins
August 08, 2020
Tweet
Share
More Decks by Willian Martins
See All by Willian Martins
Empirical Observations on the The Future of Scalable UI Architecture
wmsbill
0
150
Além do else! Categorizando Pokemóns com Pattern Matching no JavaScript
wmsbill
0
860
Back to the future of JS II: Beyond what we can foresee
wmsbill
0
120
A, B, C. 1, 2, 3. Iterables you and me.
wmsbill
0
94
Back to the future of JS II: Beyond what we can foresee
wmsbill
0
110
Back to the future of JS.
wmsbill
0
11
Node conf ar 2018.
wmsbill
0
560
Back to the future of JS
wmsbill
1
77
Back to the future of JS
wmsbill
2
270
Other Decks in Technology
See All in Technology
Bill One 開発エンジニア 紹介資料
sansan33
PRO
4
14k
CNCFの視点で捉えるPlatform Engineering - 最新動向と展望 / Platform Engineering from the CNCF Perspective
hhiroshell
0
140
ソースを読むプロセスの例
sat
PRO
15
9.9k
初めてのDatabricks Apps開発
taka_aki
1
280
混合雲環境整合異質工作流程工具運行關鍵業務 Job 的經驗分享
yaosiang
0
170
オブザーバビリティが育むシステム理解と好奇心
maruloop
1
670
OTEPsで知るOpenTelemetryの未来 / Observability Conference Tokyo 2025
arthur1
0
110
だいたい分かった気になる 『SREの知識地図』 / introduction-to-sre-knowledge-map-book
katsuhisa91
PRO
3
1.4k
AIエージェントによる業務効率化への飽くなき挑戦-AWS上の実開発事例から学んだ効果、現実そしてギャップ-
nasuvitz
2
450
ソースを読む時の思考プロセスの例-MkDocs
sat
PRO
1
150
ゼロコード計装導入後のカスタム計装でさらに可観測性を高めよう
sansantech
PRO
1
130
ヘンリー会社紹介資料(エンジニア向け) / company deck for engineer
henryofficial
0
340
Featured
See All Featured
Context Engineering - Making Every Token Count
addyosmani
8
300
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
30
2.9k
Git: the NoSQL Database
bkeepers
PRO
431
66k
Embracing the Ebb and Flow
colly
88
4.9k
We Have a Design System, Now What?
morganepeng
53
7.8k
The Cost Of JavaScript in 2023
addyosmani
55
9.1k
The Art of Programming - Codeland 2020
erikaheidi
56
14k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
9
930
Leading Effective Engineering Teams in the AI Era
addyosmani
7
600
Navigating Team Friction
lara
190
15k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.5k
jQuery: Nuts, Bolts and Bling
dougneiner
65
7.9k
Transcript
E ai, Beleza?
Quem é você!?
Pq vc tá aqui?
https://github.com/tc39/proposals
BrazilJS - ES
@wmsbill O que é this?
@wmsbill this no escopo global Browser - window Web worker
- self NodeJS - module.exports
@wmsbill this dentro de uma função?
@wmsbill this dentro de uma função?
None
@wmsbill Como fazer this ser previsível? Entender o valor de
this é complicado Function.prototype.bind Arrow function () => {}
Com .bind()
Com Arrow
@wmsbill Invocando uma função conhecida
@wmsbill Extraindo um método de um objeto
None
@wmsbill Duas sintaxes Unária : :context.method() Binária context: :method()
@wmsbill Sintaxe unária
@wmsbill Sintaxe Binária
@wmsbill
@wmsbill
@wmsbill
@wmsbill Operador Bind é útil para métodos virtuais Mas precisa
que do this para ser travado
@wmsbill Compondo sem this
@wmsbill
@wmsbill
None
@wmsbill Operador pipeline |> Sintaxe sugar para composição de funções
Cria uma cadeia de funções fluida
@wmsbill Operador pipeline |>
@wmsbill
@wmsbill
@wmsbill
@wmsbill Função com mais de um parâmetro.
@wmsbill Função com mais de um parâmetro.
@wmsbill Awaiting uma função
@wmsbill Awaiting uma função
@wmsbill Awaiting uma função
@wmsbill Awaiting uma função
@wmsbill Awaiting uma função
None
@wmsbill Smart pipeline Dois tipos bare style e topic style
() e [] são proibidos no bare style Quando () ou [] é necessário, usa- se o topic style # é um token temporário
@wmsbill Smart pipeline
@wmsbill What about curry?
None
@wmsbill Proposta de pipeline F# Extende a proposta mínima com
o passo await O passo await espera pela resolução do passo anterior.
@wmsbill Proposta de pipeline F#
@wmsbill
@wmsbill Partial application f(…) aridade = n; partialapp(f(…)) aridade =
m; m < n
@wmsbill
@wmsbill
@wmsbill Partial application no JS Possível com Function.prototype.bind .bind() trava
contexto e parametros
@wmsbill
@wmsbill Mas e o currying? É possível fazer partial application
com curry Curry ≠ Partial application Curry retorna aridade n-1
@wmsbill
@wmsbill Partial application com arrow function
None
@wmsbill Proposta partial application Cria dois novos tokens de parametros
? Para argumento único . . . para múltiplos argumentos (não está mais na spec inicial)
@wmsbill Syntaxe do partial application
@wmsbill With arbitrary parameter
None
@wmsbill Partial application em template string
@wmsbill Partial application em template string
None
@wmsbill O token . . . Espalha os argumentos não
travados Útil quando se quer travar ou o primeiro ou o último parâmetro
@wmsbill O token . . .
@wmsbill O token . . .
@wmsbill Partial application + pipeline
@wmsbill Partial application + pipeline
@wmsbill Posso usar isso em produção? Essas propostas estão em
estágios muito iniciais A adoção de uma pode mudar ou eliminar a adoção de outra Não está pronta pra prod (ainda)
https://www.twitch.tv/williandev https://twitter.com/wmsbill
[email protected]
Valeus! Falows!