SlideShare a Scribd company logo
Intro to EmberJS
Billy Onjea & Jeff Sturgis
Roadmap
1. What is EmberJS? - 5min
2. Ember core concepts - 15min
3. Ember Data - 10min
4. Ember CLI - 5min
5. Ember in action & Questions - 25min
What is EmberJS?
A JavaScript framework for Single Page Applications
Loosely based on model-view-controller - MVC
Convention over configuration, one way to do things => The Ember Way
It’s like an SDK for the web, made up of various packages and tooling
> Single Page Apps are distinguished by their ability to redraw
specific parts of the UI without requiring a browser refresh.
Ember is made up of three high-level projects
Ember
MVC-like
Ember Data
ORM-like
Ember CLI
Node tool
Top level framework
namespace and all core
objects exist here
● Ember
● Ember.Object
● Ember.Application
● Ember.Router
● Ember.Route
● Ember.Component
Everything data related is under
the DS namespace. It’s like an
ORM for JavaScript
● DS
● DS.Model
● DS.Store
● DS.Adapter
● DS.JSONAPISerializer
● DS.JSONSerializer
Ember’s command line utility
provides us with project
automation
● Provides generators
● Builds assets in dist/
● Minifies JS and CSS
● Transpiles & compiles
● Supports addon system
Ember Core Concepts
Core concepts
Project structure
File/Folder Purpose
app/
This is where your app’s models, routes, controllers,
components, templates, styles, and others are stored.
bower_components/ &
bower.json
Bower is a dependency management tool. Used in
Ember CLI to manage front-end plugins.
config/
The config directory contains the environment.js where
you can configure settings for your app.
dist/
When we build our app for deployment, the output files
will be created here.
node_modules/ &
package.json
This directory and file are from NPM. NPM is the
package manager for NodeJS. Ember is packaged as
various node modules and depends on other modules.
public/ Contains assets such as images and fonts
tests/ Automated tests for our app go here
vendor/ This is where front-end dependencies go (JS and/or
CSS) that are not managed by Bower.
ember-cli-build.js This file describes how Ember CLI should build our app
Core concepts
Your app’s directory
File/Folder Purpose
app/app.js Entry point - the first module executed
app/router.js Routes here map to app/routes/
app/routes/*.js Route handlers - respond to URL changes (singletons)
app/models/*.js Models - defines entity attrs and relations
app/components/*.js Component views
app/templates/*.hbs HTML/Handlebar templates
app/controllers/*.js Controllers (singletons)
app/styles/*.scss Contains your SASS styles
app/adapters/*.js Determine how data is persisted to backend API
app/serializers/*.js Format data before sent or received from API
app/**/* Other directories like helpers/, services/, initializers/ ...
Core concepts
From a URL path to rendered
HTML
Ember will generate instances of
various types automatically, if the
files aren’t created:
Ember.Route
Ember.Controller
Ember.Component
...
Core concepts
Ember container
Every Ember application has a
container. It’s a collection of an app’s
long-lived objects, organized by a
standardized key:
route:posts
template:posts
component:blog-post
Then in your app you would look up
specific types using this key:
“route:posts”
Ember Inspector
Core concepts
Ember resolver
The DefaultResolver defines the
default lookup rules to resolve
container lookups: templates are
looked up on Ember.TEMPLATES other
names are looked up on the
application after converting the name.
For example, ”controller:post” looks
up App.PostController by default.
Note: Ember-CLI based apps use a
resolver that is es6 module aware.
Ember Data
A library that integrates tightly with Ember
Easy interface to CRUD models from/to your server as JSON
Included by default when you create a new Ember app
Can be configured to work with any backend via its adapter pattern
Provides a single store as the central cache for models in your app
Ember Data
Ajax request
The first time your application
asks the store for the record, a
server round trip is made.
Caching
On subsequent requests, the
promise resolves with the
record immediately! The store
has cached the record - no
server round trip.
2
1
Ember Data
Models
Ember models are classes that define
the attributes, relationships, and behavior
of your data.
Records
A record is an instance of a model that
contains data loaded from the server.
Ember Data
Adapter
An adapter is an object that translates
requests from Ember, such as "find the
user with an id of 1", into requests to a
server.
For example, if your app asks for a
Person with an id of 1, how should
Ember load it?
Over HTTP or a WebSocket?
If HTTP, is the URL /person/1 or
/resources/people/1?
Ember CLI
A CLI for Ember apps - aliased as ember
Built with Node and heavily depends on the Broccoli build tool
Uses Babel to transpile and convert ES6 modules to AMD modules
Compiles SASS, LESS, handlebar templates, concatenates, minifies, etc.
Provides generators, addon system, deployment utils, dev/test server, etc.
More info at ember-cli.com
Ember CLI
Available commands
Command Purpose
ember Prints out a list of available commands
ember new <app-name> Creates app directory and generates app’s structure
ember build Builds the application into the dist/ directory
ember server Starts a web server at http://localhost:4200
ember g model <model-
name>
Generates model files
app/models/model-name.js
tests/unit/models/model-name-test.js
ember g component
<component-name>
Generates component files
app/components/component-name.js
app/templates/components/component-name.js
tests/integration/components/component-name-test.js
ember g route
<feed>
Generates route files
app/routes/feed.js
app/templates/feed.hbs
Updates app/router.js
tests/unit/routes/feed-test.js
... a lot more commands...
Ember CLI
ember-cli-build.js
This is our app’s build configuration file.
Here we can specify if we want to use
SASS or LESS, import additional files,
and more.
In this example first we installed the
SASS ember addon with:
> ember install ember-cli-sass
Compiles into: dist/assets/app.css
Ember in action
Let’s generate an app!
Questions?
Thank you! :)

More Related Content

What's hot

Concepts of Asp.Net
Concepts of Asp.NetConcepts of Asp.Net
Concepts of Asp.Net
vidyamittal
 
Asp.net,mvc
Asp.net,mvcAsp.net,mvc
Asp.net,mvc
Prashant Kumar
 
iOS Swift application architecture
iOS Swift application architectureiOS Swift application architecture
iOS Swift application architecture
Romain Rochegude
 
Word press 01
Word press 01Word press 01
Word press 01
AbhishekMondal42
 
Asp.net With mvc handson
Asp.net With mvc handsonAsp.net With mvc handson
Asp.net With mvc handson
Prashant Kumar
 
Using spring scheduler mule
Using spring scheduler muleUsing spring scheduler mule
Using spring scheduler mule
Son Nguyen
 
Learn ASP
Learn ASPLearn ASP
Learn ASP
gurchet
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation
dimuthu22
 
Server Side Programming
Server Side Programming Server Side Programming
Server Side Programming
Zac Gordon
 
Asp.net
 Asp.net Asp.net
Asp.net
Dinesh kumar
 
Active server pages
Active server pagesActive server pages
Active server pages
mcatahir947
 
Web service vm in mule
Web service vm in muleWeb service vm in mule
Web service vm in mule
Mohammed246
 
Validate soap request in mule
Validate soap request in muleValidate soap request in mule
Validate soap request in mule
Mohammed246
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
Peter Gfader
 
Spring mvc 2.0
Spring mvc 2.0Spring mvc 2.0
Spring mvc 2.0
Rudra Garnaik, PMI-ACP®
 
Soap request in mule
Soap request in mule Soap request in mule
Soap request in mule
Praneethchampion
 
Aws sqs component in mule
Aws sqs  component in muleAws sqs  component in mule
Aws sqs component in mule
Ramakrishna kapa
 
Server and Client side comparision
Server and Client side comparisionServer and Client side comparision
Server and Client side comparision
Stew Duncan
 
Active server pages
Active server pagesActive server pages
Active server pages
student
 

What's hot (19)

Concepts of Asp.Net
Concepts of Asp.NetConcepts of Asp.Net
Concepts of Asp.Net
 
Asp.net,mvc
Asp.net,mvcAsp.net,mvc
Asp.net,mvc
 
iOS Swift application architecture
iOS Swift application architectureiOS Swift application architecture
iOS Swift application architecture
 
Word press 01
Word press 01Word press 01
Word press 01
 
Asp.net With mvc handson
Asp.net With mvc handsonAsp.net With mvc handson
Asp.net With mvc handson
 
Using spring scheduler mule
Using spring scheduler muleUsing spring scheduler mule
Using spring scheduler mule
 
Learn ASP
Learn ASPLearn ASP
Learn ASP
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation
 
Server Side Programming
Server Side Programming Server Side Programming
Server Side Programming
 
Asp.net
 Asp.net Asp.net
Asp.net
 
Active server pages
Active server pagesActive server pages
Active server pages
 
Web service vm in mule
Web service vm in muleWeb service vm in mule
Web service vm in mule
 
Validate soap request in mule
Validate soap request in muleValidate soap request in mule
Validate soap request in mule
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 
Spring mvc 2.0
Spring mvc 2.0Spring mvc 2.0
Spring mvc 2.0
 
Soap request in mule
Soap request in mule Soap request in mule
Soap request in mule
 
Aws sqs component in mule
Aws sqs  component in muleAws sqs  component in mule
Aws sqs component in mule
 
Server and Client side comparision
Server and Client side comparisionServer and Client side comparision
Server and Client side comparision
 
Active server pages
Active server pagesActive server pages
Active server pages
 

Viewers also liked

65827706 introducao-engenharia-de-producao-livro-copia
65827706 introducao-engenharia-de-producao-livro-copia65827706 introducao-engenharia-de-producao-livro-copia
65827706 introducao-engenharia-de-producao-livro-copia
andressabarcson
 
Creating ambitious web application with Ember.js
Creating ambitious web application with Ember.jsCreating ambitious web application with Ember.js
Creating ambitious web application with Ember.js
Tam Le
 
Periodic Table Group Project Day 1
Periodic Table Group Project   Day 1Periodic Table Group Project   Day 1
Periodic Table Group Project Day 1
jmori1
 
Power santa eularieta
Power santa eularietaPower santa eularieta
Power santa eularieta
Rita Rotger
 
True maisha service presentation
True maisha service presentationTrue maisha service presentation
True maisha service presentation
Eric Chrispin
 
Tek13 - Creating Mobile Apps with PHP and Symfony
Tek13 - Creating Mobile Apps with PHP and SymfonyTek13 - Creating Mobile Apps with PHP and Symfony
Tek13 - Creating Mobile Apps with PHP and Symfony
Pablo Godel
 
Scarlett Falling Down
Scarlett Falling DownScarlett Falling Down
Scarlett Falling Down
Les Davy
 
Zero gravity surgery
Zero gravity surgeryZero gravity surgery
Zero gravity surgery
Jeyaminu Jayapal
 
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013АО "Самрук-Казына"
 
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
長野市議会議員小泉一真
 
Latin 1 lesson 10 share
Latin 1 lesson 10 shareLatin 1 lesson 10 share
Latin 1 lesson 10 share
polaramy
 
Referral Program for ALL!
Referral Program for ALL!Referral Program for ALL!
Referral Program for ALL!
Tanya_Shapiro
 
2011 FUM Summer Mission Project
2011 FUM Summer Mission Project2011 FUM Summer Mission Project
2011 FUM Summer Mission Project
Kelly Kellum
 
Kudavi 2.19.2016
Kudavi 2.19.2016Kudavi 2.19.2016
Kudavi 2.19.2016
Tom Currier
 
Project m
Project mProject m
Project m
Alex Wu
 
Social media, jobs, computers, (1)
Social media, jobs, computers, (1)Social media, jobs, computers, (1)
Social media, jobs, computers, (1)
Michael Baker
 
Иммуноблисс «скорая помощь» клеткам иммунной системы
Иммуноблисс «скорая помощь» клеткам иммунной системыИммуноблисс «скорая помощь» клеткам иммунной системы
Иммуноблисс «скорая помощь» клеткам иммунной системы
Елена Шальнова
 
Mobile Apps And Your Business
Mobile Apps And Your BusinessMobile Apps And Your Business
Mobile Apps And Your Business
front9tech
 
HAPPY NEW YEAR
HAPPY NEW YEARHAPPY NEW YEAR
HAPPY NEW YEAR
Rahul Gavade
 
Perspectivas Empresariales 2016 - Bizkaia
Perspectivas Empresariales 2016 - BizkaiaPerspectivas Empresariales 2016 - Bizkaia
Perspectivas Empresariales 2016 - Bizkaia
Cámara de Comercio de Bilbao
 

Viewers also liked (20)

65827706 introducao-engenharia-de-producao-livro-copia
65827706 introducao-engenharia-de-producao-livro-copia65827706 introducao-engenharia-de-producao-livro-copia
65827706 introducao-engenharia-de-producao-livro-copia
 
Creating ambitious web application with Ember.js
Creating ambitious web application with Ember.jsCreating ambitious web application with Ember.js
Creating ambitious web application with Ember.js
 
Periodic Table Group Project Day 1
Periodic Table Group Project   Day 1Periodic Table Group Project   Day 1
Periodic Table Group Project Day 1
 
Power santa eularieta
Power santa eularietaPower santa eularieta
Power santa eularieta
 
True maisha service presentation
True maisha service presentationTrue maisha service presentation
True maisha service presentation
 
Tek13 - Creating Mobile Apps with PHP and Symfony
Tek13 - Creating Mobile Apps with PHP and SymfonyTek13 - Creating Mobile Apps with PHP and Symfony
Tek13 - Creating Mobile Apps with PHP and Symfony
 
Scarlett Falling Down
Scarlett Falling DownScarlett Falling Down
Scarlett Falling Down
 
Zero gravity surgery
Zero gravity surgeryZero gravity surgery
Zero gravity surgery
 
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013
Презентация П.Хауза на расширенное совещание АО "Самрук-Қазына" 07.02.2013
 
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
第2回 ★★オンラインくるま座集会★★ 2013.10.03 at 小泉一真くるま座談話室
 
Latin 1 lesson 10 share
Latin 1 lesson 10 shareLatin 1 lesson 10 share
Latin 1 lesson 10 share
 
Referral Program for ALL!
Referral Program for ALL!Referral Program for ALL!
Referral Program for ALL!
 
2011 FUM Summer Mission Project
2011 FUM Summer Mission Project2011 FUM Summer Mission Project
2011 FUM Summer Mission Project
 
Kudavi 2.19.2016
Kudavi 2.19.2016Kudavi 2.19.2016
Kudavi 2.19.2016
 
Project m
Project mProject m
Project m
 
Social media, jobs, computers, (1)
Social media, jobs, computers, (1)Social media, jobs, computers, (1)
Social media, jobs, computers, (1)
 
Иммуноблисс «скорая помощь» клеткам иммунной системы
Иммуноблисс «скорая помощь» клеткам иммунной системыИммуноблисс «скорая помощь» клеткам иммунной системы
Иммуноблисс «скорая помощь» клеткам иммунной системы
 
Mobile Apps And Your Business
Mobile Apps And Your BusinessMobile Apps And Your Business
Mobile Apps And Your Business
 
HAPPY NEW YEAR
HAPPY NEW YEARHAPPY NEW YEAR
HAPPY NEW YEAR
 
Perspectivas Empresariales 2016 - Bizkaia
Perspectivas Empresariales 2016 - BizkaiaPerspectivas Empresariales 2016 - Bizkaia
Perspectivas Empresariales 2016 - Bizkaia
 

Similar to Intro to EmberJS

Full slidescr16
Full slidescr16Full slidescr16
Full slidescr16
Lucio Grenzi
 
The road to Ember.js 2.0
The road to Ember.js 2.0The road to Ember.js 2.0
The road to Ember.js 2.0
Codemotion
 
Ember presentation
Ember presentationEmber presentation
Ember presentation
Daniel N
 
Spring tutorial
Spring tutorialSpring tutorial
Spring tutorial
Sanjoy Kumer Deb
 
Workshop 16: EmberJS Parte I
Workshop 16: EmberJS Parte IWorkshop 16: EmberJS Parte I
Workshop 16: EmberJS Parte I
Visual Engineering
 
Introduction to Ember.js
Introduction to Ember.jsIntroduction to Ember.js
Introduction to Ember.js
Mike Nicholaides
 
How To Scale v2
How To Scale v2How To Scale v2
How To Scale v2
Georgio_1999
 
Entity framework1
Entity framework1Entity framework1
Entity framework1
Girish Gowda
 
Ember - introduction
Ember - introductionEmber - introduction
Ember - introduction
Harikrishnan C
 
Ruby Rails Web Development
Ruby Rails Web DevelopmentRuby Rails Web Development
Ruby Rails Web Development
Sonia Simi
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN Stack
Rob Davarnia
 
Ember,js: Hipster Hamster Framework
Ember,js: Hipster Hamster FrameworkEmber,js: Hipster Hamster Framework
Ember,js: Hipster Hamster Framework
Billy Shih
 
Rails
RailsRails
Rails
SHC
 
Asp.net
Asp.netAsp.net
Ember js java script framework
Ember js   java script frameworkEmber js   java script framework
Ember js java script framework
sara stanford
 
Introduction to sails.js
Introduction to sails.jsIntroduction to sails.js
Introduction to sails.js
Amit Bidwai
 
.NET,ASP .NET, Angular Js,LinQ
.NET,ASP .NET, Angular Js,LinQ.NET,ASP .NET, Angular Js,LinQ
.NET,ASP .NET, Angular Js,LinQ
Avijit Shaw
 
Ruby On Rails Basics
Ruby On Rails BasicsRuby On Rails Basics
Ruby On Rails Basics
Amit Solanki
 
Ember CLI & Ember Tooling
Ember CLI & Ember ToolingEmber CLI & Ember Tooling
Ember CLI & Ember Tooling
Mark Provan
 
SMC302 Building Serverless Web Applications
SMC302 Building Serverless Web ApplicationsSMC302 Building Serverless Web Applications
SMC302 Building Serverless Web Applications
Amazon Web Services
 

Similar to Intro to EmberJS (20)

Full slidescr16
Full slidescr16Full slidescr16
Full slidescr16
 
The road to Ember.js 2.0
The road to Ember.js 2.0The road to Ember.js 2.0
The road to Ember.js 2.0
 
Ember presentation
Ember presentationEmber presentation
Ember presentation
 
Spring tutorial
Spring tutorialSpring tutorial
Spring tutorial
 
Workshop 16: EmberJS Parte I
Workshop 16: EmberJS Parte IWorkshop 16: EmberJS Parte I
Workshop 16: EmberJS Parte I
 
Introduction to Ember.js
Introduction to Ember.jsIntroduction to Ember.js
Introduction to Ember.js
 
How To Scale v2
How To Scale v2How To Scale v2
How To Scale v2
 
Entity framework1
Entity framework1Entity framework1
Entity framework1
 
Ember - introduction
Ember - introductionEmber - introduction
Ember - introduction
 
Ruby Rails Web Development
Ruby Rails Web DevelopmentRuby Rails Web Development
Ruby Rails Web Development
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN Stack
 
Ember,js: Hipster Hamster Framework
Ember,js: Hipster Hamster FrameworkEmber,js: Hipster Hamster Framework
Ember,js: Hipster Hamster Framework
 
Rails
RailsRails
Rails
 
Asp.net
Asp.netAsp.net
Asp.net
 
Ember js java script framework
Ember js   java script frameworkEmber js   java script framework
Ember js java script framework
 
Introduction to sails.js
Introduction to sails.jsIntroduction to sails.js
Introduction to sails.js
 
.NET,ASP .NET, Angular Js,LinQ
.NET,ASP .NET, Angular Js,LinQ.NET,ASP .NET, Angular Js,LinQ
.NET,ASP .NET, Angular Js,LinQ
 
Ruby On Rails Basics
Ruby On Rails BasicsRuby On Rails Basics
Ruby On Rails Basics
 
Ember CLI & Ember Tooling
Ember CLI & Ember ToolingEmber CLI & Ember Tooling
Ember CLI & Ember Tooling
 
SMC302 Building Serverless Web Applications
SMC302 Building Serverless Web ApplicationsSMC302 Building Serverless Web Applications
SMC302 Building Serverless Web Applications
 

Recently uploaded

2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
Łukasz Chruściel
 
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
Crescat
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
Ayan Halder
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOMLORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
lorraineandreiamcidl
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
Hornet Dynamics
 
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdf
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdfAutomated software refactoring with OpenRewrite and Generative AI.pptx.pdf
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdf
timtebeek1
 
SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024
Hironori Washizaki
 
GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
Neo4j
 
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Łukasz Chruściel
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j
 
Transform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR SolutionsTransform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR Solutions
TheSMSPoint
 
Webinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for EmbeddedWebinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for Embedded
ICS
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
Green Software Development
 
Artificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension FunctionsArtificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension Functions
Octavian Nadolu
 
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise EditionWhy Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
Envertis Software Solutions
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
Peter Muessig
 
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CDKuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
rodomar2
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate
 
Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
Philip Schwarz
 

Recently uploaded (20)

2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
 
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
 
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOMLORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
LORRAINE ANDREI_LEQUIGAN_HOW TO USE ZOOM
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
 
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdf
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdfAutomated software refactoring with OpenRewrite and Generative AI.pptx.pdf
Automated software refactoring with OpenRewrite and Generative AI.pptx.pdf
 
SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024SWEBOK and Education at FUSE Okinawa 2024
SWEBOK and Education at FUSE Okinawa 2024
 
GraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph TechnologyGraphSummit Paris - The art of the possible with Graph Technology
GraphSummit Paris - The art of the possible with Graph Technology
 
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
 
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit ParisNeo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
Neo4j - Product Vision and Knowledge Graphs - GraphSummit Paris
 
Transform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR SolutionsTransform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR Solutions
 
Webinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for EmbeddedWebinar On-Demand: Using Flutter for Embedded
Webinar On-Demand: Using Flutter for Embedded
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
 
Artificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension FunctionsArtificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension Functions
 
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise EditionWhy Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
Why Choose Odoo 17 Community & How it differs from Odoo 17 Enterprise Edition
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
 
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CDKuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
 
Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
 

Intro to EmberJS

  • 1. Intro to EmberJS Billy Onjea & Jeff Sturgis
  • 2. Roadmap 1. What is EmberJS? - 5min 2. Ember core concepts - 15min 3. Ember Data - 10min 4. Ember CLI - 5min 5. Ember in action & Questions - 25min
  • 4. A JavaScript framework for Single Page Applications Loosely based on model-view-controller - MVC Convention over configuration, one way to do things => The Ember Way It’s like an SDK for the web, made up of various packages and tooling > Single Page Apps are distinguished by their ability to redraw specific parts of the UI without requiring a browser refresh.
  • 5. Ember is made up of three high-level projects Ember MVC-like Ember Data ORM-like Ember CLI Node tool Top level framework namespace and all core objects exist here ● Ember ● Ember.Object ● Ember.Application ● Ember.Router ● Ember.Route ● Ember.Component Everything data related is under the DS namespace. It’s like an ORM for JavaScript ● DS ● DS.Model ● DS.Store ● DS.Adapter ● DS.JSONAPISerializer ● DS.JSONSerializer Ember’s command line utility provides us with project automation ● Provides generators ● Builds assets in dist/ ● Minifies JS and CSS ● Transpiles & compiles ● Supports addon system
  • 7. Core concepts Project structure File/Folder Purpose app/ This is where your app’s models, routes, controllers, components, templates, styles, and others are stored. bower_components/ & bower.json Bower is a dependency management tool. Used in Ember CLI to manage front-end plugins. config/ The config directory contains the environment.js where you can configure settings for your app. dist/ When we build our app for deployment, the output files will be created here. node_modules/ & package.json This directory and file are from NPM. NPM is the package manager for NodeJS. Ember is packaged as various node modules and depends on other modules. public/ Contains assets such as images and fonts tests/ Automated tests for our app go here vendor/ This is where front-end dependencies go (JS and/or CSS) that are not managed by Bower. ember-cli-build.js This file describes how Ember CLI should build our app
  • 8. Core concepts Your app’s directory File/Folder Purpose app/app.js Entry point - the first module executed app/router.js Routes here map to app/routes/ app/routes/*.js Route handlers - respond to URL changes (singletons) app/models/*.js Models - defines entity attrs and relations app/components/*.js Component views app/templates/*.hbs HTML/Handlebar templates app/controllers/*.js Controllers (singletons) app/styles/*.scss Contains your SASS styles app/adapters/*.js Determine how data is persisted to backend API app/serializers/*.js Format data before sent or received from API app/**/* Other directories like helpers/, services/, initializers/ ...
  • 9. Core concepts From a URL path to rendered HTML Ember will generate instances of various types automatically, if the files aren’t created: Ember.Route Ember.Controller Ember.Component ...
  • 10. Core concepts Ember container Every Ember application has a container. It’s a collection of an app’s long-lived objects, organized by a standardized key: route:posts template:posts component:blog-post Then in your app you would look up specific types using this key: “route:posts” Ember Inspector
  • 11. Core concepts Ember resolver The DefaultResolver defines the default lookup rules to resolve container lookups: templates are looked up on Ember.TEMPLATES other names are looked up on the application after converting the name. For example, ”controller:post” looks up App.PostController by default. Note: Ember-CLI based apps use a resolver that is es6 module aware.
  • 13. A library that integrates tightly with Ember Easy interface to CRUD models from/to your server as JSON Included by default when you create a new Ember app Can be configured to work with any backend via its adapter pattern Provides a single store as the central cache for models in your app
  • 14. Ember Data Ajax request The first time your application asks the store for the record, a server round trip is made. Caching On subsequent requests, the promise resolves with the record immediately! The store has cached the record - no server round trip. 2 1
  • 15. Ember Data Models Ember models are classes that define the attributes, relationships, and behavior of your data. Records A record is an instance of a model that contains data loaded from the server.
  • 16. Ember Data Adapter An adapter is an object that translates requests from Ember, such as "find the user with an id of 1", into requests to a server. For example, if your app asks for a Person with an id of 1, how should Ember load it? Over HTTP or a WebSocket? If HTTP, is the URL /person/1 or /resources/people/1?
  • 18. A CLI for Ember apps - aliased as ember Built with Node and heavily depends on the Broccoli build tool Uses Babel to transpile and convert ES6 modules to AMD modules Compiles SASS, LESS, handlebar templates, concatenates, minifies, etc. Provides generators, addon system, deployment utils, dev/test server, etc. More info at ember-cli.com
  • 19. Ember CLI Available commands Command Purpose ember Prints out a list of available commands ember new <app-name> Creates app directory and generates app’s structure ember build Builds the application into the dist/ directory ember server Starts a web server at http://localhost:4200 ember g model <model- name> Generates model files app/models/model-name.js tests/unit/models/model-name-test.js ember g component <component-name> Generates component files app/components/component-name.js app/templates/components/component-name.js tests/integration/components/component-name-test.js ember g route <feed> Generates route files app/routes/feed.js app/templates/feed.hbs Updates app/router.js tests/unit/routes/feed-test.js ... a lot more commands...
  • 20. Ember CLI ember-cli-build.js This is our app’s build configuration file. Here we can specify if we want to use SASS or LESS, import additional files, and more. In this example first we installed the SASS ember addon with: > ember install ember-cli-sass Compiles into: dist/assets/app.css
  • 21. Ember in action Let’s generate an app!

Editor's Notes

  1. With Server Side Apps, all off the client-side state would be wiped out and re-created on every HTTP request. With Single Page Apps, frameworks need a place to store an application’s long-lived objects and a standardized way to look them up. This is why the idea of a container exists. Dependencies (singletons and factories) can be looked up and used as needed.
  2. The Ember container uses the DefaultResolver under the hood to look up instances and to resolve factories. Example: owner.lookup('component:my-component) instanceof owner.resolveRegistration('component:my-component') //=> true
  3. JSON API standardizes how JavaScript applications talk to servers The store automatically caches records. If a record had already been loaded, asking for it again will always return the same Model instance. This minimizes the number of round-trips to the server, and allows your application to render its UI to the user as fast as possible.