SlideShare une entreprise Scribd logo
1  sur  72
Rails, Postgres,
Angular, and Bootstrap
The Power Stack
@davetron5000
Journey through the
“stack”
Full Stack is important
“Jack of all trades,
master of none…
…oftentimes better
than master of one”
UI
Learn about design
MY AMAZING
APP!
MY AMAZING
APP!
Text
Modular Type Scale
Subhead 1
Subhead 2
Subhead 3
Body Text
Captions & Secondary Text
About Us
The place for all your needs
We’ve got everything you
could ever want and then
some. It’s just that simple to
be as awesome as we are,
and it shows.
You can’t find this much great
stuff anywhere else, so what
are you waiting for? Sign up
Sign Up
Log In
Help
<div class="row">
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
<div class="col-md-1">.col-md-1</div>
</div>
<div class="row">
<div class="col-md-8">.col-md-8</div>
<div class="col-md-4">.col-md-4</div>
</div>
<form class="form-horizontal">
<div class="form-group">
<label for="inputEmail3" class="col-sm-2 control-label">Email</label>
<div class="col-sm-10">
<input type="email" class="form-control" id="inputEmail3" placeholder="Email">
</div>
</div>
<div class="form-group">
<label for="inputPassword3" class="col-sm-2 control-label">Password</label>
<div class="col-sm-10">
<input type="password" class="form-control" id="inputPassword3" placeholder="Password">
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10">
<div class="checkbox">
<label>
<input type="checkbox"> Remember me
</label>
</div>
</div>
</div>
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10">
<button type="submit" class="btn btn-default">Sign in</button>
</div>
</div>
</form>
<form>
<label for="inputEmail3" class="col-sm-2 control-label">Email</label>
<input type="email" class="form-control" id="inputEmail3" placeholder="Email">
<label for="inputPassword3" class="col-sm-2 control-label">Password</label>
<input type="password" class="form-control" id="inputPassword3" placeholder="Password">
<label>
<input type="checkbox"> Remember me
</label>
<button type="submit" class="btn btn-default">Sign in</button>
</form>
<button type=“button” class=“btn btn-default”>Default</button>
<button type=“button” class=“btn btn-primary”>Primary</button>
<button type=“button” class=“btn btn-primary btn-lg”>Large</button>
<button type=“button” class=“btn btn-primary btn-xs”>XS</button>
Default
Default
Default
Default
<div class=“alert alert-success”>…</div>
alert-info
alert-warning
alert-danger
Panel
Icons
Sub-panel
Well
Disabled
Badge
Interaction
JavaScript & jQuery
You shouldn’t think about
locating DOM elements and
firing or responding to events
<div class=“dialog js-dismissable”>
<h1>OK?</h1>
<nav>
<button data-dismiss=“yes”>Close</button>
<button data-ok>OK</button>
</nav>
</div>
$(“.js-dimissable”).find(“[data-ok]”).click(function() {
// ...
});
Components &
Behavior
<dialog>
<title>OK?</title>
<dismiss>Close</dismiss>
<confirm>OK</confirm>
</dialog>
dialog.on_confirm(function() {
// ...
});
Some
Documentation
Kinda
Works
No
Support
Yeah, there’s probably some
code comments, and it’s
entirely possible I used great
variable names. Functions
and objects should be
consistent, but probably
aren’t. I think there was a
demo page somewhere,
maybe?
It still doesn’t handle that
weird case on IE 8, and I
never tested what happens if
you use two containers in the
same DOM subtree, but CSS
polyfills mostly work for major
browsers. No, there’s no test
suite.
I’m moving onto a project
using Node, Elixir, Redis,
Mongo, and Kubernetes, so
the best thing to do is hang
out on the Slack channel. I
live in New Orleans, but work
Amsterdam hours, so I’m not
always around.
JS
<aside class=“modal-dialog”>
<h1>{{ title }}</h1>
<p ng-if=“message”>
{{ message }}
</p>
<button ng-click=“dismiss()”>Close</button>
<button ng-click=“ok(‘ok’)”>OK</button>
<button ng-click=“ok(‘maybe’)”>Maybe</button>
</aside>
“DialogController”,
function($scope, $dialog, opts) {
$scope.title = opts.title;
$scope.message = opts.message;
$scope.ok = function(data) {
if (data == ‘ok’) {
$dialog.confirm();
}
else {
$dialog.confirm(withData: data)
}
}
$scope.dismiss = function() {
$dialog.cancel();
}
User = $resource(“/users/:id”);
$scope.user = User.get(id: $routeParams.id);
<article>
<h1>{{ user.name }}</h1>
<h2>{{ user.email }}</h2>
<ul ng-repeat=“login in user.recentLogins”>
<li>
<strong>{{ login.date }}</strong> -
{{ login.ipAddress }}
</li>
</ul>
</article>
angular.module(‘controllers’).controller(
“DialogController”,
function($scope, $dialog, opts) {
$scope.title = opts.title;
$scope.message = opts.message;
$scope.ok = function(data) {
if (data == ‘ok’) {
$dialog.confirm();
}
else {
$dialog.confirm(withData: data)
}
}
$scope.dismiss = function() {
$dialog.cancel();
}
});
“customConfirmation”,
function() {
return {
confirm: function($dialog,data) {
if (data == ‘ok’) $dialog.confirm();
else $dialog.confirm(withData: data);
}
}
}
);
angular.module(‘controllers’).controller(
“DialogController”,
function($scope, $dialog, opts, customConfirmation) {
$scope.title = opts.title;
$scope.message = opts.message;
$scope.ok = customConfirmation.confirm;
$scope.dismiss = function() {
$dialog.cancel();
}
Angular is Popular
The “Back End”
Middleware
Parse HTTP
Extract params, headers,
cookies, etc
Route to code
Read result
Generate response, cookies,
headers, etc.
Database Access
Package Assets
Run Tests
Schema Management
Configuration & Deployment
Parse HTTP
Extract params, headers,
cookies, etc
Route to code
Read result
Generate response, cookies,
headers, etc.
Database Access
Package Assets
Run Tests
Schema Management
Configuration & Deployment
Plumbing
Your Code
Don’t make decisions
Data
Durability
Integrity
Speed
Modeling
SQL RDBMS
First: Learn SQL. You
won’t regret it.
ALTER TABLE
users
ADD CONSTRAINT
valid_emails
CHECK (
( guest = true AND
email ! ‘[A-Za-z0-9._%-]+@example.com’)
OR
( guest = false AND
email ~ ‘[A-Za-z0-9._%-]+@example.com’)
)
CREATE INDEX
users_name_index
ON
users (lower(name))
SELECT * FROM users
WHERE lower(name) = ‘bob’;
UPDATE users
SET config = ‘auto_save => true,
color => default’::hstore;
CREATE INDEX user_config
ON users USING GIN(config);
ALTER TABLE
users
ADD COLUMN
config HSTORE;
SELECT * FROM users
WHERE config @> ‘auto_save => true’;
ALTER TABLE
users
ADD COLUMN
roles text[];
UPDATE users
SET roles = ‘{staff,admin}’;
CREATE INDEX user_roles
ON users USING GIN(roles);
SELECT * FROM users
WHERE roles @> ‘{admin}’;
ALTER TABLE
transactions
ADD COLUMN
braintree_response JSONB;
UPDATE transactions
SET braintree_response = ‘{
“processor_response”: “decline”,
“processor_code”: 1234,
“details”: {
“charge_type”: “authorization”,
“amount”: 12.45,
“zip”: “20002”
}
CREATE INDEX txn_responses
ON transactions
USING GIN(braintree_response);
SELECT * FROM
transactions
WHERE
roles @>
‘{“processor_response”: “decline”}’::jsonb;
SQL Knowledge + Postgres
== Powerful data layer
Putting it all Together
Be Honest about
Weaknesses
Bootstrap
• JS-based components require jQuery
• Angular-UI-Bootstrap
Angular
• Protractor (end-to-end testing) totally disconnected
from Rails/back-end
• Use Capybara/PhantomJS for E2E testing
Rails
• Strange view/front-end/JS/AJAX design
• Avoid
• Disable turbolinks
• Asset Pipeline oddities
• Learn to use it—it’s actually powerful
Rails
• Database Migrations “DSL”
• You are not making a database-agnostic app
• Use execute
• Use SQL-based schema
config.active_record.schema_format = :sql
Rails
• ActiveRecord
• Examine queries in the log—look for
optimizations
• Let SQL shine
• Don’t fear .where() or
ActiveRecord::Base.connection.exec_query()
Postgres
• Stored Procedures
• Triggers
• Avoid putting business logic here
You don’t have to use
every feature
These are powerful
tools
The reduce the decisions
you have to make to only
what’s important.
If you are making decisions
not related to your product…
…consider Bootstrap,
Angular, Rails, or Postgres

Contenu connexe

Tendances

Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology Ayes Chinmay
 
Hacking Your Way To Better Security - php[tek] 2016
Hacking Your Way To Better Security - php[tek] 2016Hacking Your Way To Better Security - php[tek] 2016
Hacking Your Way To Better Security - php[tek] 2016Colin O'Dell
 
AngulrJS Overview
AngulrJS OverviewAngulrJS Overview
AngulrJS OverviewEyal Vardi
 
Learning jQuery in 30 minutes
Learning jQuery in 30 minutesLearning jQuery in 30 minutes
Learning jQuery in 30 minutesSimon Willison
 
Scalable vector ember
Scalable vector emberScalable vector ember
Scalable vector emberMatthew Beale
 
jQuery Anti-Patterns for Performance & Compression
jQuery Anti-Patterns for Performance & CompressionjQuery Anti-Patterns for Performance & Compression
jQuery Anti-Patterns for Performance & CompressionPaul Irish
 
Devoxx 2014-webComponents
Devoxx 2014-webComponentsDevoxx 2014-webComponents
Devoxx 2014-webComponentsCyril Balit
 
Introduction to jQuery
Introduction to jQueryIntroduction to jQuery
Introduction to jQuerymanugoel2003
 
jQuery Presentation
jQuery PresentationjQuery Presentation
jQuery PresentationRod Johnson
 
jQuery and Rails, Sitting in a Tree
jQuery and Rails, Sitting in a TreejQuery and Rails, Sitting in a Tree
jQuery and Rails, Sitting in a Treeadamlogic
 
Hacking Your Way To Better Security - DrupalCon Baltimore 2017
Hacking Your Way To Better Security - DrupalCon Baltimore 2017Hacking Your Way To Better Security - DrupalCon Baltimore 2017
Hacking Your Way To Better Security - DrupalCon Baltimore 2017Colin O'Dell
 

Tendances (20)

Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology
Internet and Web Technology (CLASS-10) [Node.js] | NIC/NIELIT Web Technology
 
jQuery Best Practice
jQuery Best Practice jQuery Best Practice
jQuery Best Practice
 
Hacking Your Way To Better Security - php[tek] 2016
Hacking Your Way To Better Security - php[tek] 2016Hacking Your Way To Better Security - php[tek] 2016
Hacking Your Way To Better Security - php[tek] 2016
 
JQuery introduction
JQuery introductionJQuery introduction
JQuery introduction
 
jQuery
jQueryjQuery
jQuery
 
jQuery
jQueryjQuery
jQuery
 
Javascript
JavascriptJavascript
Javascript
 
22 j query1
22 j query122 j query1
22 j query1
 
AngulrJS Overview
AngulrJS OverviewAngulrJS Overview
AngulrJS Overview
 
Learning jQuery in 30 minutes
Learning jQuery in 30 minutesLearning jQuery in 30 minutes
Learning jQuery in 30 minutes
 
jQuery
jQueryjQuery
jQuery
 
Scalable vector ember
Scalable vector emberScalable vector ember
Scalable vector ember
 
jQuery Anti-Patterns for Performance & Compression
jQuery Anti-Patterns for Performance & CompressionjQuery Anti-Patterns for Performance & Compression
jQuery Anti-Patterns for Performance & Compression
 
Devoxx 2014-webComponents
Devoxx 2014-webComponentsDevoxx 2014-webComponents
Devoxx 2014-webComponents
 
Javascript1
Javascript1Javascript1
Javascript1
 
Web 6 | JavaScript DOM
Web 6 | JavaScript DOMWeb 6 | JavaScript DOM
Web 6 | JavaScript DOM
 
Introduction to jQuery
Introduction to jQueryIntroduction to jQuery
Introduction to jQuery
 
jQuery Presentation
jQuery PresentationjQuery Presentation
jQuery Presentation
 
jQuery and Rails, Sitting in a Tree
jQuery and Rails, Sitting in a TreejQuery and Rails, Sitting in a Tree
jQuery and Rails, Sitting in a Tree
 
Hacking Your Way To Better Security - DrupalCon Baltimore 2017
Hacking Your Way To Better Security - DrupalCon Baltimore 2017Hacking Your Way To Better Security - DrupalCon Baltimore 2017
Hacking Your Way To Better Security - DrupalCon Baltimore 2017
 

Similaire à Rails, Postgres, Angular, and Bootstrap: The Power Stack

Implementation of GUI Framework part3
Implementation of GUI Framework part3Implementation of GUI Framework part3
Implementation of GUI Framework part3masahiroookubo
 
Practical Ruby Projects (Alex Sharp)
Practical Ruby Projects (Alex Sharp)Practical Ruby Projects (Alex Sharp)
Practical Ruby Projects (Alex Sharp)MongoSF
 
Practical Ruby Projects with MongoDB - MongoSF
Practical Ruby Projects with MongoDB - MongoSFPractical Ruby Projects with MongoDB - MongoSF
Practical Ruby Projects with MongoDB - MongoSFAlex Sharp
 
Angular JS2 Training Session #1
Angular JS2 Training Session #1Angular JS2 Training Session #1
Angular JS2 Training Session #1Paras Mendiratta
 
[Coscup 2012] JavascriptMVC
[Coscup 2012] JavascriptMVC[Coscup 2012] JavascriptMVC
[Coscup 2012] JavascriptMVCAlive Kuo
 
Rapid web development, the right way.
Rapid web development, the right way.Rapid web development, the right way.
Rapid web development, the right way.nubela
 
The Best (and Worst) of Django
The Best (and Worst) of DjangoThe Best (and Worst) of Django
The Best (and Worst) of DjangoJacob Kaplan-Moss
 
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010Practical Ruby Projects with MongoDB - Ruby Kaigi 2010
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010Alex Sharp
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescriptDavid Furber
 
jAPS 2 0 - Presentation Layer Comparison
jAPS 2 0 - Presentation Layer ComparisonjAPS 2 0 - Presentation Layer Comparison
jAPS 2 0 - Presentation Layer ComparisonWilliam Ghelfi
 
Backbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVCBackbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVCpootsbook
 
Mojolicious, real-time web framework
Mojolicious, real-time web frameworkMojolicious, real-time web framework
Mojolicious, real-time web frameworktaggg
 
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)
YGLF 2015 -  Boom Performance | Eran Zinman (daPulse)YGLF 2015 -  Boom Performance | Eran Zinman (daPulse)
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)Eran Zinman
 
BOOM Performance
BOOM PerformanceBOOM Performance
BOOM Performancedapulse
 

Similaire à Rails, Postgres, Angular, and Bootstrap: The Power Stack (20)

Implementation of GUI Framework part3
Implementation of GUI Framework part3Implementation of GUI Framework part3
Implementation of GUI Framework part3
 
Practical Ruby Projects (Alex Sharp)
Practical Ruby Projects (Alex Sharp)Practical Ruby Projects (Alex Sharp)
Practical Ruby Projects (Alex Sharp)
 
Practical Ruby Projects with MongoDB - MongoSF
Practical Ruby Projects with MongoDB - MongoSFPractical Ruby Projects with MongoDB - MongoSF
Practical Ruby Projects with MongoDB - MongoSF
 
Angular JS2 Training Session #1
Angular JS2 Training Session #1Angular JS2 Training Session #1
Angular JS2 Training Session #1
 
[Coscup 2012] JavascriptMVC
[Coscup 2012] JavascriptMVC[Coscup 2012] JavascriptMVC
[Coscup 2012] JavascriptMVC
 
Rapid web development, the right way.
Rapid web development, the right way.Rapid web development, the right way.
Rapid web development, the right way.
 
The Best (and Worst) of Django
The Best (and Worst) of DjangoThe Best (and Worst) of Django
The Best (and Worst) of Django
 
Jquery fundamentals
Jquery fundamentalsJquery fundamentals
Jquery fundamentals
 
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010Practical Ruby Projects with MongoDB - Ruby Kaigi 2010
Practical Ruby Projects with MongoDB - Ruby Kaigi 2010
 
Real life-coffeescript
Real life-coffeescriptReal life-coffeescript
Real life-coffeescript
 
前端概述
前端概述前端概述
前端概述
 
Rails and security
Rails and securityRails and security
Rails and security
 
jAPS 2 0 - Presentation Layer Comparison
jAPS 2 0 - Presentation Layer ComparisonjAPS 2 0 - Presentation Layer Comparison
jAPS 2 0 - Presentation Layer Comparison
 
Backbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVCBackbone.js — Introduction to client-side JavaScript MVC
Backbone.js — Introduction to client-side JavaScript MVC
 
Mojolicious, real-time web framework
Mojolicious, real-time web frameworkMojolicious, real-time web framework
Mojolicious, real-time web framework
 
Java script
Java scriptJava script
Java script
 
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)
YGLF 2015 -  Boom Performance | Eran Zinman (daPulse)YGLF 2015 -  Boom Performance | Eran Zinman (daPulse)
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)
 
BOOM Performance
BOOM PerformanceBOOM Performance
BOOM Performance
 
Wt unit 2 ppts client sied technology
Wt unit 2 ppts client sied technologyWt unit 2 ppts client sied technology
Wt unit 2 ppts client sied technology
 
Wt unit 2 ppts client side technology
Wt unit 2 ppts client side technologyWt unit 2 ppts client side technology
Wt unit 2 ppts client side technology
 

Dernier

WSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - KeynoteWSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - KeynoteWSO2
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension AidPhilip Schwarz
 
What Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the SituationWhat Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the SituationJuha-Pekka Tolvanen
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...Shane Coughlan
 
WSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park masabamasaba
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...masabamasaba
 
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...masabamasaba
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastPapp Krisztián
 
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburgmasabamasaba
 
Announcing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareAnnouncing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareJim McKeeth
 
%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in soweto%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in sowetomasabamasaba
 
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...masabamasaba
 
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benonimasabamasaba
 
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2
 
WSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaSWSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaSWSO2
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...masabamasaba
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2
 

Dernier (20)

WSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - KeynoteWSO2Con204 - Hard Rock Presentation - Keynote
WSO2Con204 - Hard Rock Presentation - Keynote
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
What Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the SituationWhat Goes Wrong with Language Definitions and How to Improve the Situation
What Goes Wrong with Language Definitions and How to Improve the Situation
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
WSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go Platformless
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Knoxville Psychic Readings, Attraction spells,Br...
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
 
Announcing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareAnnouncing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK Software
 
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
Abortion Pill Prices Boksburg [(+27832195400*)] 🏥 Women's Abortion Clinic in ...
 
%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in soweto%in Soweto+277-882-255-28 abortion pills for sale in soweto
%in Soweto+277-882-255-28 abortion pills for sale in soweto
 
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AI
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
 
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
 
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
 
WSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaSWSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaS
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 

Rails, Postgres, Angular, and Bootstrap: The Power Stack

Notes de l'éditeur

  1. • thanks for coming • this is a powerful stack • can solve many common problems
  2. • stop along the way • outline common problems when working in that part • see how these technologies solve those problems
  3. • important to understand why this is important • we are at a full stack conference
  4. • I like the more rare, complete version • with an holistic view, you can solve problems end-to-end • little friction between what you want to deliver and what you can deliver • work with specialists if you need them
  5. • this is what your users think of as “the app” • how should it look? • how should it work?
  6. • We aren’t creating products differentiated on HCI • We aren’t creating a product that innovates on HCI
  7. • solving people’s problems • helping someone be more successful at their job • can’t build the former without a lot of the latter
  8. • a little goes a long way • with a few hours reading, you will be leveled up
  9. • Grid based design foundation of print and web design
  10. • Everything on a page should be aligned to a grid
  11. • when it’s aligned, your design is cohesive, polished, and professional
  12. • The grid reduces choices to just a few that will work great. • you can apply the same logic to font sizes • you just need six or seven fonts
  13. • The grid reduces choices to just a few that will work great. • you can apply the same logic to font sizes • you just need six or seven fonts
  14. • the page comes together • you can direct the user with just font size
  15. • when forms and complex components are needed, use padding/margins that work with the grid and type scale
  16. • There are many many CSS frameworks • Bootstrap is full-featured, easy to use, easy to understand, and hard to mess up
  17. • It has a grid and modular type scale •
  18. • Your forms won’t look terrible
  19. • Many other components that you need for common tasks
  20. • web apps aren’t static • simplest ones need dialogs, showing/hiding things, async loading
  21. • This means JavaScript • JS and JQ are very low level
  22. • Your code should be at the component and behavior level of abstraction
  23. • You want your logic tested without clicking around in a browser • You don’t want your view littered with data elements and js classes
  24. • You can achieve this in JS or jQuery • but you end up making your own degenerate framework • that is undocumented and no one can use
  25. • you shouldn’t build a framework while you are building features • you should use the hard work of others • Angular can do all of these things
  26. • it’s clear what the intent is here, and how this will behave
  27. • Aside from the boilerplate, this is simple code • it’s not wrapped up in the framework • it’s easily testable • it just uses simple javascript objects.
  28. • uses promises so you have no callback hell
  29. • you have a clear way to extract and abstract code • there’s nothing really fancy or magical about it
  30. • you have a clear way to extract and abstract code • there’s nothing really fancy or magical about it
  31. • don’t undervalue this • lots of resources, help, documentation • you won’t find systemic issues in popular frameworks
  32. • the UI has to talk to some sort of back-end • this is where business logic goes
  33. • such a businessy lame term, but it’s on point • middleware does a lot
  34. • receive HTTP requests • parse them • call some code • figure out a response • service assets • talk to the database • run tests • etc etc. This is a LOT
  35. • Your first problem in middleware land is you don’t want to write plumbing • you don’t want to spend time debating how to route URLs • you can’t afford to discuss database management or param parsing
  36. • your business problems are necessarily complex • the way you solve them should not be MORE complex
  37. • you want a framework that makes the right decisions for you • you want to work in an expressive high-level language • so all you think about is your problem and how to structure the code
  38. • Rails is the gold standard • Convention-based, makes all decisions for you • No Rails team ever debates how to package assets, route URLs, parse the query string, connect to the database, run tests, or manage the schema
  39. • Ruby is a wonderful language • Highly expressive; simple code • Abstraction is straightforward • If all you know is JavaScript, C#, or Java, you owe it to yourself to try Rails
  40. • Like most middleware, Rails wants to be everything. We’ll get to that • part of being a full stack developer is getting the best out of your tools
  41. • data is the heart of every business • you could survive the loss of code, but not of data
  42. When you ask it to write, it writes
  43. • what you put in comes out exactly • you can ensure consistency and correctness
  44. • you want access to be optimized for your use-cases
  45. • You want powerful tools to describe what is and isn’t correct and valid data.
  46. • SQL might have the longest period of relevance of any technology • The relational model has stood the test of time • It can seem archaic
  47. • If you aren’t comfortable with SQL datbases, level up
  48. • Postgres excels at these things • it’s free and open-source • it has noSQL-like features that few other SQL databases have
  49. • Few RDBMS’ have check constraints like this. This prevents rogue agents, buggy code, or bad judgement from putting bad data into your database
  50. • Powerful indexing features. More than just indexing on a field, you can do indexes on transformed data as well as partial indexes
  51. • Powerful, indexable data types to model your data without making a ton of extra tables
  52. • Powerful, indexable data types to model your data without making a ton of extra tables
  53. • You can even use Postgres as a document data store by putting JSON in it. The JSON can be indexed.
  54. • You can even use Postgres as a document data store by putting JSON in it. The JSON can be indexed.