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
Silex (phpquebec)
Search
Igor Wiedler
July 12, 2013
Programming
6
450
Silex (phpquebec)
Igor Wiedler
July 12, 2013
Tweet
Share
More Decks by Igor Wiedler
See All by Igor Wiedler
Redis Bedtime Stories
igorw
1
330
Wide Event Analytics (LISA19)
igorw
4
930
a day in the life of a request
igorw
0
160
production: an owner's manual
igorw
0
180
The Power of 2
igorw
0
320
LISP 1.5 Programmer's Manual: A Dramatic Reading
igorw
0
460
The Moral Character of Software
igorw
1
290
interdisciplinary computing (domcode)
igorw
0
310
miniKanren (clojure berlin)
igorw
1
310
Other Decks in Programming
See All in Programming
NOT A HOTEL - 建築や人と融合し、自由を創り出すソフトウェア
not_a_hokuts
2
570
new(1.26) ← これすき / kamakura.go #8
utgwkk
0
1.7k
CSC307 Lecture 14
javiergs
PRO
0
450
CSC307 Lecture 13
javiergs
PRO
0
310
Rで始めるML・LLM活用入門
wakamatsu_takumu
0
160
守る「だけ」の優しいEMを抜けて、 事業とチームを両方見る視点を身につけた話
maroon8021
3
290
AWS×クラウドネイティブソフトウェア設計 / AWS x Cloud-Native Software Design
nrslib
4
410
encoding/json/v2のUnmarshalはこう変わった:内部実装で見る設計改善
kurakura0916
0
320
go directiveを最新にしすぎないで欲しい話──あるいは、Go 1.26からgo mod initで作られるgo directiveの値が変わる話 / Go 1.26 リリースパーティ
arthur1
2
470
Geminiの機能を調べ尽くしてみた
naruyoshimi
0
200
Head of Engineeringが現場で回した生産性向上施策 2025→2026
gessy0129
0
210
モジュラモノリスにおける境界をGoのinternalパッケージで守る
magavel
0
3.4k
Featured
See All Featured
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.1k
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
118
110k
New Earth Scene 8
popppiees
1
1.7k
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
260
How to Think Like a Performance Engineer
csswizardry
28
2.5k
Typedesign – Prime Four
hannesfritz
42
3k
Code Review Best Practice
trishagee
74
20k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
850
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
How to Talk to Developers About Accessibility
jct
2
140
The SEO identity crisis: Don't let AI make you average
varn
0
400
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
150
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