Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Silex (phpquebec)
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Igor Wiedler
July 12, 2013
Programming
450
6
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Silex (phpquebec)
Igor Wiedler
July 12, 2013
More Decks by Igor Wiedler
See All by Igor Wiedler
Redis Bedtime Stories
igorw
1
380
Wide Event Analytics (LISA19)
igorw
4
950
a day in the life of a request
igorw
0
180
production: an owner's manual
igorw
0
200
The Power of 2
igorw
0
350
LISP 1.5 Programmer's Manual: A Dramatic Reading
igorw
0
490
The Moral Character of Software
igorw
1
330
interdisciplinary computing (domcode)
igorw
0
330
miniKanren (clojure berlin)
igorw
1
340
Other Decks in Programming
See All in Programming
wkhtmltopdfの次どうするか問題2026
willnet
2
1.7k
[GoCon2026] When Goroutines Are Not Enough: Runtime Locality in High-Throughput Go
takehaya
6
2.5k
Workers Cache を知る
syumai
0
250
動作中のプログラムの中身をリアルタイムに覗く / Realtime Debugger for CSharp with Roslyn
prota
1
1.2k
Verilogで学ぶCPU自作入門.pdf
uyuki234
8
3.3k
JAWS-UG 東京支部が始める、JAWS-UG支部コラボ / JAWS-UG lunchtime LT Collaboration
y0hgi
0
130
C#の現在地 進化の歴史と、AI時代の.NET Everywhere
neuecc
4
3.8k
Are APIs Still Relevant in the AI Era?
soyuka
0
310
ハーネス設計入門 〜 基礎知識の整理から実務へのステップアップ 〜
kinopeee
18
16k
AI Agent時代のリアーキテクチャ戦略と実践
hokaccha
9
5k
個人開発基盤をまるごとCloudflareに引っ越して爆速で総合的体験を向上させた話
tinykitten
0
210
JPUG勉強会 OSSデータベースの内部構造を理解しよう(第2回)
oga5
0
270
Featured
See All Featured
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
730
RailsConf 2023
tenderlove
30
1.6k
Design in an AI World
tapps
1
330
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
2k
What does AI have to do with Human Rights?
axbom
PRO
1
2.4k
Ten Tips & Tricks for a 🌱 transition
stuffmc
1
240
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.4k
Code Reviewing Like a Champion
maltzj
528
40k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
520
Typedesign – Prime Four
hannesfritz
42
3.2k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
530
Transcript
None
@igorwesome
Chunking
Context more abstract more concrete
Frameworks Zero
Frameworks Zero Don’t re- invent the wheel! You’re bloated and
buggy!
Frameworks Zero Conventions Libraries Wiring
Conventions Libraries Wiring Coding standard Directory layout Community
Conventions Libraries Wiring Routing ORM Templating etc.
Conventions Libraries Wiring Base config Library glue Bootstrap
Conventions Libraries Wiring Frameworks Zero
Conventions Libraries Wiring Frameworks Zero Because downloading stuff is hard!
None
Conventions Libraries Wiring
Conventions Libraries Wiring
Conventions Libraries Wiring Libraries Frameworks
Silex
Glorified Router
$app = new Silex\Application(); $app->get('/', function () { return "Hello
world!"; }); $app->run();
$app->get('/blog/{id}', 'Blog::showPost'); $app->post('/blog/{id}', 'Blog::createPost'); $app->put('/blog/{id}', function ($id) { ... })
->assert('id', '\d+');
$app->before(function () { ... }); $app->after(function () { ... });
$app->finish(function () { ... });
use Symfony\Component\HttpFoundation\Response; $app->error(function (\Exception $e, $code) { return new Response('Whoops!',
$code); });
$app->redirect('/hello'); $app->json($data); $app->sendFile($file);
Dependency Injection Container
class Application extends Pimple
$app['routes'] $app['url_matcher'] $app['kernel']
$app['routes']->add(...);
$app['debug'] = true;
$app['url_matcher'] = $app->share( function ($app) { return new MyUrlMatcher(); }
);
$app['foo'] = $app->share( function ($app) { return new Foo($app['bar']); }
);
$app['foo']
User Interface for Symfony2
http-kernel http-foundation event-dispatcher routing silex
REQ REP
None
silex app
silex app
diff -u symfony silex
--- symfony +++ silex @@ -1,3 +1 @@ -conventions -static
compilation -lots of services +choices
Glorified Router
Glorified Router Dependency Injection Container
Glorified Router Dependency Injection Container User Interface for Symfony2
Conventions Libraries Wiring Libraries Frameworks
Ω
Questions? @igorwesome silex.sensiolabs.org yolophp.com stackphp.com