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
Parsers in JavaScript
Search
Leif Gensert
April 22, 2020
Technology
0
45
Parsers in JavaScript
This is an introduction to parsers in JavaScript with examples of PEG.js
Leif Gensert
April 22, 2020
Tweet
Share
More Decks by Leif Gensert
See All by Leif Gensert
Sorbet - Is it really that tasty?
leifg
0
43
state_of_functional_programming.pdf
leifg
0
41
Bugs - What are they good for
leifg
0
22
Building Event Sourced Apps
leifg
1
820
Unicode Spaß
leifg
0
40
Event Sourcing - The Story Telling of Processes
leifg
1
68
Elixir Releases
leifg
0
140
Introduction to Rails
leifg
0
50
JRuby - The enterprise view
leifg
1
100
Other Decks in Technology
See All in Technology
関係性が駆動するアジャイル──GPTに人格を与えたら、対話を通してふりかえりを習慣化できた話
mhlyc
0
140
"プロポーザルってなんか怖そう"という境界を超えてみた@TSUDOI by giftee Tech #1
shilo113
0
170
Adminaで実現するISMS/SOC2運用の効率化 〜 アカウント管理編 〜
shonansurvivors
4
430
10年の共創が示す、これからの開発者と企業の関係 ~ Crossroad
soracom
PRO
1
690
AI駆動開発を推進するためにサービス開発チームで 取り組んでいること
noayaoshiro
0
240
社内報はAIにやらせよう / Let AI handle the company newsletter
saka2jp
8
1.3k
Oracle Base Database Service 技術詳細
oracle4engineer
PRO
11
78k
【Kaigi on Rails 事後勉強会LT】MeはどうしてGirlsに? 私とRubyを繋いだRail(s)
joyfrommasara
0
220
AWS IoT 超入門 2025
hattori
0
290
Where will it converge?
ibknadedeji
0
200
ACA でMAGI システムを社内で展開しようとした話
mappie_kochi
1
310
カンファレンスに託児サポートがあるということ / Having Childcare Support at Conferences
nobu09
1
500
Featured
See All Featured
Code Review Best Practice
trishagee
72
19k
Speed Design
sergeychernyshev
32
1.2k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
A Tale of Four Properties
chriscoyier
160
23k
Optimising Largest Contentful Paint
csswizardry
37
3.4k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.4k
Building Flexible Design Systems
yeseniaperezcruz
329
39k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
970
Git: the NoSQL Database
bkeepers
PRO
431
66k
Building a Modern Day E-commerce SEO Strategy
aleyda
43
7.7k
Build your cross-platform service in a week with App Engine
jlugia
232
18k
The Cult of Friendly URLs
andyhume
79
6.6k
Transcript
Hello World Parsers with JavaScript
None
Programming === Hiking
Compilers Reverse Engineering Building Developer Tools
You don't Say
Every single program can be reduced to Input Transformation Output
* Former Boss
None
Human Readable Parsing Machine Readable Grammar
None
"in 11 seconds" 11 "11 seconds ago" -11 "in 5
minutes" 300 "in 1 minute and 30 seconds ago" 90 "now" 0
Leif Demo
// 1 + 2 add(1,2) // 1 + (5 -
3) add(1, subtract(5,3)) // 1 + 5 * 3 add(1, multiply(5,3)) // (1 + 5) * 3 multiply(add(1,5), 3)
Leif Demo
What else? Domain Specific NLP Config Files (Re)Implement Programming Languages
Abstract Syntax Tree add(1, multiply(5,3)) { type: "callExpression", name: "add",
arguments: [1 { type: "callExpression", name: "add", arguments: [5, 3] }] }
Why?
Focus!
None
Leif Demo
- Parsers seem intimidating - Helps you understand Recursion -
Try out formulon.io
Shopping List
Back
Back