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
Practical React in Marionette application
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
mthenw
April 10, 2015
Programming
650
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Practical React in Marionette application
meet.js Poznań
mthenw
April 10, 2015
More Decks by mthenw
See All by mthenw
How to make better technical decisions
mthenw
0
110
Globally distributed applications with Serverless Framework
mthenw
1
210
The State of Serverless
mthenw
0
770
The State of Serverless (PCUG)
mthenw
0
260
Apex: The Holy Grail of AWS Lambda
mthenw
0
230
Microservices on AWS ECS
mthenw
8
870
Working with single-threaded event loop
mthenw
1
370
Bingo Bango Mongo
mthenw
6
450
Are you Redis? Introduction to Redis.
mthenw
2
770
Other Decks in Programming
See All in Programming
setup-vp GitLab対応の裏側
naokihaba
0
150
動作中のプログラムの中身をリアルタイムに覗く / Realtime Debugger for CSharp with Roslyn
prota
1
1.7k
JRuby: Past, Present, and Future
headius
0
220
モジュールの視点からSwiftを読み解く #iosdc
s_shimotori
0
310
AI が書く Go コードの品質を劇的に向上させる Linter: “declscope”
mpyw
0
480
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
490
iOSDC Japan 2026 - Swiftで作って学ぼう!データベース自作入門
kaseken
2
450
re:Inventに行く前に知っておきたい現地参加のノウハウ
nokomoro3
0
340
FreeBSDでZabbixを動かす
kenkino
0
350
マイコン向けの軽量Ruby「PicoRuby」で各種デバイスを制御するネイティブアプリの実現手法
bash0c7
0
470
Androidだけじゃない、DroidKaigiで広がった私の技術スタック
akkeylab
0
110
Agents on Rails - Rails at Scale 2026
irinanazarova
0
320
Featured
See All Featured
The agentic SEO stack - context over prompts
schlessera
0
950
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
2.2k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
250
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.6k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
1
620
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.8k
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
900
Docker and Python
trallard
47
4.2k
A Soul's Torment
seathinner
8
3.7k
The untapped power of vector embeddings
frankvandijk
2
1.9k
The Language of Interfaces
destraynor
162
27k
Transcript
Practical React In Marionette application
@mthenw
None
Egnyte Web UI
Egnyte Web UI Backbone/Marionette require.js karma/jasmine JSHint/JSCS underscore templates
not so much unit tests a lot of HTML duplication
overcomplicated business logic two-way binding (rivets.js)
New feature - Audit Reports
None
DataGrid PoC
None
DataGrid PoC less code reusable components easy to test
React + Marionette
no revolution
React Bridge
var ReactBridge = Backbone.Marionette.ItemView.extend({ template: "#react-bridge-template", initialize: function (options) {
this.options = options; }, onRender: function () { React.render(this.initializeComponent(this.options), this.el); }, onClose: function () { React.unmountComponentAtNode(this.el); } });
var Grid = ReactBridge.extend({ initializeComponent: function (options) { return DataGridComponent({
title: "Cool Grid", desc: "with awesome data", collection: options.collection, ... }); } });
App.Settings.layout.content.show( new Grid({collection: collection}) );
None
Model Component model’s attributes as props update on change getModel().set(..,
..)
Best practises
Best practises JSX
var Header = React.createClass({ render() { return ( <header className={
`${this.props.classNamePrefix}-header content-header` }> <div> <h1 key="header"><span>{ this.t(this.props.title) }</span></h1> <span className="desc" key="desc">{ this.t(this.props.desc) }</span> { filters } <div className="actions" key="actions">{ actions }</div> </div> </header> ); } }); var Header = React.createClass({ render() { return ( React.createElement( "header", {className: `${this.props.classNamePrefix}-header content-header`}, React.createElement("div", null, React.createElement("h1", {key: “header"}, React.createElement("span", null, this.t(this.props.title) )), React.createElement("span", {className: "desc", key: "desc"}, this.t(this.props.desc) ), filters, React.createElement("div", {className: "actions", key: "actions"}, actions ) ) ) ); } });
Best practises JSX small components beware of using state
var DataGrid = React.createClass({ render() { return <div className="datagrid" >
<Header /> <Notifications /> <Table /> <Pagination /> </div>; } });
Best practises JSX small components even smaller components beware of
using state
var Icon = React.createClass({ render() { return <i className={"icon-" +
this.props.icon} />; } });
Best practises JSX small components even smaller components beware of
using state no revolution
+1
Thanks!