SlideShare ist ein Scribd-Unternehmen logo
1 von 71
Downloaden Sie, um offline zu lesen
The raise of web developers
@loicknuchel
?
Loïc Knuchel
Geek passionné
Freelance
Développeur web full-stack
Entrepreneur
Cookers / SalooN
loicknuchel@gmail.com
@loicknuchel
http://loic.knuchel.org/
L’histoire du smartphone
Juin 2007
Lancement de l’iPhone 1
Septembre 2008
Sortie du HTC G1
avec Android
● Nouvelles possibilités
○ UX
○ Technique
○ Business
● Un écosystème à bâtir
● Nouvelle stack technique
● Peu de personnes formées
● Développer plusieurs fois la même chose
● Environnements très spécifiques (offline, puissance, versions, diversité...)
La WebView
Idée
Coder des applications
entièrement dans la WebView
Avantages :
● Technologies et environnements connus
● Cross-platform
PhoneGap / Cordova
Mars 2009 :
Lancement de PhoneGap par Nitobi
Octobre 2011 :
Rachat de Nitobi par Adobe
Séparation de la technologie (Cordova) et des services commerciaux (PhoneGap)
Oups...
● UI moche
● UI peu réactive
● loin du look & feel natif
Mauvais support des standards du
web dans la WebView
Peu d’outils / librairies
Téléphones peu puissants
● App de mauvaise qualité
● Bugs
Souvent pour des projets à petit
budget...
Aujourd’hui
● Téléphones puissants (et de + en +)
● Très bon support des standards web dans la WebView
● Beaucoup d’outils / librairies
Ionic c’est quoi ?
+ =
Stack technologique
Natif
Web
Téléphone & APIs natives
Cordova : webview +
JavaScript bridges
Angular
Ionic
Application
Dév web = Dév mobile
DX
“We want to cater to the 99% who just want to build something functional quickly
and not break the bank to do it.” - Max Lynch
DX
#Platform continuity
#CLI
#Backend services
#Push
#Deploy
#Package#Auth
#Analytics #Ionic View
#Native plugins #Ionic Market
#Ionic Creator
@ionitron
Ionic is a complete ecosystem !
One more thing...
Hybrid apps have superpowers...
Hybrid superpowers
●
App Store installs are broken !
?
http://bit.ly/voxxrin
App Store installs are broken !
Deep linking Install tracking
Hybrid superpowers
Web App :
● Cross-platform
● Accès instantané
● Deep link
● Offline
http://bit.ly/voxxrin-bdx-lkn
Hybrid superpowers
Web App :
● Cross-platform
● Accès instantané
● Deep link
● Offline
Progressive Web App :
● Installation instantanée
● Lancement depuis la Home
● Push notifications
Hybrid superpowers
Web App :
● Cross-platform
● Accès instantané
● Deep link
● Offline
Progressive Web App :
● Installation instantanée
● Lancement depuis la Home
● Push notifications
Native App :
● Accès complet au téléphone
Hybrid superpowers
●
App Store deployment is broken !
Apple : ~ 2 jours
Google : ~ 2 heures
Hybrid superpowers
●
Nouveautés depuis Ionic 1
● Angular 2 (+ TypeScript)
● Navigation push/pop
● Nouveaux composants
○ DateTime
○ Toast
○ Searchbar
○ Segment
Getting started
Install nodejs & npm
$ npm install -g ionic@beta
$ ionic start demoApp --v2 --ts
$ cd demoApp && ionic serve
♬ ♫ ♬ ♫ Your Ionic app is ready to go! ♬ ♫ ♬ ♫
Getting started
Install mobile sdk (Android ou iOS)
$ sudo npm install -g cordova
$ ionic platform add android
$ ionic run android
Structure de fichiers
index.html
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="UTF-8">
<title>Ionic</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<meta name="format-detection" content="telephone=no">
<meta name="msapplication-tap-highlight" content="no">
<link ios-href="build/css/app.ios.css" rel="stylesheet">
<link md-href="build/css/app.md.css" rel="stylesheet">
<link wp-href="build/css/app.wp.css" rel="stylesheet">
</head>
<body>
<!-- this Ionic's root component and where the app will load -->
<ion-app></ion-app>
<!-- cordova.js required for cordova apps -->
<script src="cordova.js"></script>
<!-- Polyfill needed for platforms without Promise and Collection support -->
<script src="build/js/es6-shim.min.js"></script>
<!-- Zone.js and Reflect-metadata -->
<script src="build/js/Reflect.js"></script>
<script src="build/js/zone.js"></script>
<!-- the bundle which is built from the app's source code -->
<script src="build/js/app.bundle.js"></script>
</body>
</html>
app.ts
import {App, Platform} from 'ionic-angular';
import {StatusBar} from 'ionic-native';
import {TabsPage} from './pages/tabs/tabs';
@App({
template: '<ion-nav [root]="rootPage"></ion-nav>',
config: {} // http://ionicframework.com/docs/v2/api/config/Config/
})
export class MyApp {
rootPage: any = TabsPage;
constructor(platform: Platform) {
platform.ready().then(() => {
// Okay, so the platform is ready and our plugins are available.
// Here you can do any higher level native things you might need.
StatusBar.styleDefault();
});
}
}
page1.ts
import {Page} from 'ionic-angular';
@Page({
templateUrl: 'build/pages/page1/page1.html'
})
export class Page1 {
constructor() {
}
}
<ion-navbar *navbar>
<ion-title>Tab 1</ion-title>
</ion-navbar>
<ion-content padding class="page1">
<h2>Welcome to Ionic!</h2>
<p>
This starter project comes with simple
tabs-based layout for apps that are going to
primarily use a Tabbed UI.
</p>
<p>
Take a look at the <code>app/</code>
directory to add or change tabs, update any
existing page or create new pages.
</p>
</ion-content>
page1.ts
import {Page} from 'ionic-angular';
@Page({
template: `
<ion-navbar *navbar>
<ion-title>Tab 1</ion-title>
</ion-navbar>
<ion-content padding class="page1">
<h2>Welcome to Ionic!</h2>
<p>
This starter project comes with simple tabs-based layout for apps that are going to primarily
use a Tabbed UI.
</p>
</ion-content>`
})
export class Page1 {
constructor() {}
}
page1.ts
import {Page} from 'ionic-angular';
@Page({
styles: [`
.page1 h2 {
color: red;
}
`],
template: `...`
})
export class Page1 {
constructor() {}
}
Angular 1 vs Angular 2
● bootstrap manuel
● Filter => Pipe
● Controllers => Components
● Directives => Components
● $scope => Class properties
● Services => Injectables
Template
● Bindings :
● Pipes :
● Propriétés / Input :
● Evénements / Output :
● Double binding :
● Templates :
● Local variables :
● Boucles :
Your favorite hero is: {{favoriteHero}}
<span>{{movie.title | uppercase}}</span>
<a [href]="angularDocsUrl">Angular Docs</a>
<button (click)="toggleMovie()"></button>
<input [(ngModel)]="favoriteMovie" />
<div *ngIf="movies.length === 0">No movies</div>
<video-player #player></video-player>
<button (click)="player.pause()">Pause</button>
<ul *ngFor="let movie of movies">
<li>{{movie.title}}</li>
</ul>
Créer une nouvelle page
todo.page.ts todo.html todo.scss
import {Page} from 'ionic-angular';
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
constructor() { }
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-content class="todo-page">
</ion-content>
.todo-page {
.done {
text-decoration: line-through;
}
}
import {App, Platform} from 'ionic-angular';
import {StatusBar} from 'ionic-native';
import {TabsPage} from './pages/tabs/tabs';
import {TodoPage} from "./pages/todo/todo.page";
@App({
template: '<ion-nav [root]="rootPage"></ion-nav>',
config: {}
})
export class MyApp {
rootPage: any = TodoPage;
constructor(platform: Platform) {
platform.ready().then(() => {
StatusBar.styleDefault();
});
}
}
// http://ionicframework.com/docs/v2/theming/
// App Shared Imports
// --------------------------------------------------
// These are the imports which make up the design of
this app.
// By default each design mode includes these shared
imports.
// App Shared Sass variables belong in app.variables.
scss.
@import "../pages/page1/page1";
@import "../pages/page2/page2";
@import "../pages/page3/page3";
@import "../pages/todo/todo";
app.ts theme/app.core.scss
Ionic2 TODO list
import {Page} from 'ionic-angular';
class Todo {
constructor(
public name: string,
public done: boolean = false
) {}
}
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
constructor() { }
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-content class="todo-page">
</ion-content>
Ionic2 TODO list
import {Page} from 'ionic-angular';
class Todo {
constructor(
public name: string,
public done: boolean = false
) {}
}
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
todos: Todo[] = [
new Todo('todo 1'),
new Todo('todo 2'),
new Todo('todo 3')
];
constructor() { }
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-content class="todo-page">
</ion-content>
Ionic2 TODO list
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-content class="todo-page">
<ion-list>
<ion-item *ngFor="let todo of todos" [hidden]="todo.done">
<ion-label>{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done"></ion-checkbox>
</ion-item>
<ion-item *ngFor="let todo of todos" [hidden]="!todo.done">
<ion-label class="done">{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox>
</ion-item>
</ion-list>
</ion-content>
Ionic2 TODO list
import {Page} from 'ionic-angular';
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
newTodo: string = '';
todos: Todo[] = [
new Todo('todo 1'),
new Todo('todo 2'),
new Todo('todo 3')
];
constructor() { }
create(text: string): void {
this.todos.push(new Todo(text));
this.newTodo = '';
}
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-toolbar>
<ion-input type="text" [(ngModel)]="newTodo" placeholder="Nouvelle tâche">
</ion-input>
<ion-buttons end>
<button (click)="create(newTodo)">
<ion-icon name="send"></ion-icon>
</button>
</ion-buttons>
</ion-toolbar>
<ion-content class="todo-page">
<ion-list>
...
</ion-list>
</ion-content>
Ionic2 TODO list
import {Page} from 'ionic-angular';
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
newTodo: string = '';
todos: Todo[] = [...];
constructor() { }
create(text: string): void { ... }
delete(todo: Todo): void {
const i = this.todos.indexOf(todo);
if(i >= 0) {
this.todos.splice(i, 1);
}
}
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-toolbar>
...
</ion-toolbar>
<ion-content class="todo-page">
<ion-list>
<ion-item *ngFor="let todo of todos" [hidden]="todo.done">
<ion-label>{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done"></ion-checkbox>
</ion-item>
<ion-item *ngFor="..." [hidden]="!todo.done" (click)="delete(todo)">
<ion-label class="done">{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox>
</ion-item>
</ion-list>
</ion-content>
Ionic2 TODO list
import {Page} from 'ionic-angular';
@Page({
templateUrl: 'build/pages/todo/todo.html'
})
export class TodoPage {
newTodo: string = '';
todos: Todo[] = [...];
constructor() { }
create(text: string): void { ... }
delete(todo: Todo): void {
const i = this.todos.indexOf(todo);
if(i >= 0) {
this.todos.splice(i, 1);
}
}
}
<ion-navbar *navbar>
<ion-title>Todos</ion-title>
</ion-navbar>
<ion-toolbar>
...
</ion-toolbar>
<ion-content class="todo-page">
<ion-list>
<ion-item *ngFor="let todo of todos" [hidden]="todo.done">
<ion-label>{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done"></ion-checkbox>
</ion-item>
<ion-item *ngFor="..." [hidden]="!todo.done" (click)="delete(todo)">
<ion-label class="done">{{todo.name}}</ion-label>
<ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox>
</ion-item>
</ion-list>
</ion-content>
Pour tester ce weekend...
Pour tester ce weekend...
http://ionicframework.com/docs/v2/
https://github.com/driftyco/ionic-conference-app
https://github.com/saloonapp/saloon-app
http://mcgivery.com/15-ionic-framework-2-resources/ (60+ maintenant…)
https://angular.io/docs/ts/latest/cookbook/
https://forum.ionicframework.com/
http://loic.knuchel.org/blog/
Questions ?
@loicknuchel

Weitere ähnliche Inhalte

Was ist angesagt?

Cross Platform Mobile Apps with the Ionic Framework
Cross Platform Mobile Apps with the Ionic FrameworkCross Platform Mobile Apps with the Ionic Framework
Cross Platform Mobile Apps with the Ionic Framework
Troy Miles
 

Was ist angesagt? (20)

Ionic Crash Course! Hack-a-ton SF
Ionic Crash Course! Hack-a-ton SFIonic Crash Course! Hack-a-ton SF
Ionic Crash Course! Hack-a-ton SF
 
Ionic Framework: Let's build amazing apps. No Excuses!
Ionic Framework: Let's build amazing apps. No Excuses!Ionic Framework: Let's build amazing apps. No Excuses!
Ionic Framework: Let's build amazing apps. No Excuses!
 
Ionic Mobile Applications - Hybrid Mobile Applications Without Compromises
Ionic Mobile Applications - Hybrid Mobile Applications Without CompromisesIonic Mobile Applications - Hybrid Mobile Applications Without Compromises
Ionic Mobile Applications - Hybrid Mobile Applications Without Compromises
 
Hybrid app development with ionic
Hybrid app development with ionicHybrid app development with ionic
Hybrid app development with ionic
 
Ionic 2: Mobile apps with the Web
Ionic 2: Mobile apps with the WebIonic 2: Mobile apps with the Web
Ionic 2: Mobile apps with the Web
 
Developing Hybrid Applications with IONIC
Developing Hybrid Applications with IONICDeveloping Hybrid Applications with IONIC
Developing Hybrid Applications with IONIC
 
Ionic Framework
Ionic FrameworkIonic Framework
Ionic Framework
 
Cross-Platform Mobile Development with Ionic Framework and Angular
Cross-Platform Mobile Development with Ionic Framework and AngularCross-Platform Mobile Development with Ionic Framework and Angular
Cross-Platform Mobile Development with Ionic Framework and Angular
 
Creating an hybrid app in minutes with Ionic Framework
Creating an hybrid app in minutes with Ionic FrameworkCreating an hybrid app in minutes with Ionic Framework
Creating an hybrid app in minutes with Ionic Framework
 
Mobile Web Development with HTML5
Mobile Web Development with HTML5Mobile Web Development with HTML5
Mobile Web Development with HTML5
 
Ionic framework one day training
Ionic framework one day trainingIonic framework one day training
Ionic framework one day training
 
Intro to ionic 2
Intro to ionic 2Intro to ionic 2
Intro to ionic 2
 
Cross Platform Mobile Apps with the Ionic Framework
Cross Platform Mobile Apps with the Ionic FrameworkCross Platform Mobile Apps with the Ionic Framework
Cross Platform Mobile Apps with the Ionic Framework
 
Introduction to Ionic framework
Introduction to Ionic frameworkIntroduction to Ionic framework
Introduction to Ionic framework
 
From Idea to App (or “How we roll at Small Town Heroes”)
From Idea to App (or “How we roll at Small Town Heroes”)From Idea to App (or “How we roll at Small Town Heroes”)
From Idea to App (or “How we roll at Small Town Heroes”)
 
Building an Ionic hybrid mobile app with TypeScript
Building an Ionic hybrid mobile app with TypeScript Building an Ionic hybrid mobile app with TypeScript
Building an Ionic hybrid mobile app with TypeScript
 
React Native for multi-platform mobile applications
React Native for multi-platform mobile applicationsReact Native for multi-platform mobile applications
React Native for multi-platform mobile applications
 
Ionic CLI Adventures
Ionic CLI AdventuresIonic CLI Adventures
Ionic CLI Adventures
 
Workshop Ionic Framework - CC FE & UX
Workshop Ionic Framework - CC FE & UXWorkshop Ionic Framework - CC FE & UX
Workshop Ionic Framework - CC FE & UX
 
App developer as a Web developer (ROROSyd - Jul 15)
App developer as a Web developer (ROROSyd - Jul 15)App developer as a Web developer (ROROSyd - Jul 15)
App developer as a Web developer (ROROSyd - Jul 15)
 

Ähnlich wie Ionic2 - the raise of web developer, Riviera DEV le 17/06/2016

HotPush with Ionic 2 and CodePush
HotPush with Ionic 2 and CodePushHotPush with Ionic 2 and CodePush
HotPush with Ionic 2 and CodePush
Evan Schultz
 
Appcelerator Titanium Intro
Appcelerator Titanium IntroAppcelerator Titanium Intro
Appcelerator Titanium Intro
Nicholas Jansma
 

Ähnlich wie Ionic2 - the raise of web developer, Riviera DEV le 17/06/2016 (20)

Ionic2
Ionic2Ionic2
Ionic2
 
NativeScript and Angular
NativeScript and AngularNativeScript and Angular
NativeScript and Angular
 
PhoneGap
PhoneGapPhoneGap
PhoneGap
 
Ignite your app development with Angular, NativeScript and Firebase
Ignite your app development with Angular, NativeScript and FirebaseIgnite your app development with Angular, NativeScript and Firebase
Ignite your app development with Angular, NativeScript and Firebase
 
Angularjs Tutorial for Beginners
Angularjs Tutorial for BeginnersAngularjs Tutorial for Beginners
Angularjs Tutorial for Beginners
 
Myths of Angular 2: What Angular Really Is
Myths of Angular 2: What Angular Really IsMyths of Angular 2: What Angular Really Is
Myths of Angular 2: What Angular Really Is
 
Phone gap development, testing, and debugging
Phone gap development, testing, and debuggingPhone gap development, testing, and debugging
Phone gap development, testing, and debugging
 
Introduction to PhoneGap
Introduction to PhoneGapIntroduction to PhoneGap
Introduction to PhoneGap
 
Progressive Web Apps
Progressive Web AppsProgressive Web Apps
Progressive Web Apps
 
Tutorial: Develop Mobile Applications with AngularJS
Tutorial: Develop Mobile Applications with AngularJSTutorial: Develop Mobile Applications with AngularJS
Tutorial: Develop Mobile Applications with AngularJS
 
Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...
Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...
Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...
 
HotPush with Ionic 2 and CodePush
HotPush with Ionic 2 and CodePushHotPush with Ionic 2 and CodePush
HotPush with Ionic 2 and CodePush
 
Intro to PhoneGap
Intro to PhoneGapIntro to PhoneGap
Intro to PhoneGap
 
Appcelerator Titanium Intro
Appcelerator Titanium IntroAppcelerator Titanium Intro
Appcelerator Titanium Intro
 
Cross Platform Mobile App Development
Cross Platform Mobile App DevelopmentCross Platform Mobile App Development
Cross Platform Mobile App Development
 
Intro to Ionic for Building Hybrid Mobile Applications
Intro to Ionic for Building Hybrid Mobile ApplicationsIntro to Ionic for Building Hybrid Mobile Applications
Intro to Ionic for Building Hybrid Mobile Applications
 
NCDevCon 2017 - Cross Platform Mobile Apps
NCDevCon 2017 - Cross Platform Mobile AppsNCDevCon 2017 - Cross Platform Mobile Apps
NCDevCon 2017 - Cross Platform Mobile Apps
 
Ionic2 First Lesson of Four
Ionic2 First Lesson of FourIonic2 First Lesson of Four
Ionic2 First Lesson of Four
 
Automating Your Way out of the Dark Ages: Our Experience with (And Without) P...
Automating Your Way out of the Dark Ages: Our Experience with (And Without) P...Automating Your Way out of the Dark Ages: Our Experience with (And Without) P...
Automating Your Way out of the Dark Ages: Our Experience with (And Without) P...
 
22Flutter.pdf
22Flutter.pdf22Flutter.pdf
22Flutter.pdf
 

Mehr von Loïc Knuchel

Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
Loïc Knuchel
 
Devoxx 2015, ionic chat
Devoxx 2015, ionic chatDevoxx 2015, ionic chat
Devoxx 2015, ionic chat
Loïc Knuchel
 
Des maths et des recommandations - Devoxx 2014
Des maths et des recommandations - Devoxx 2014Des maths et des recommandations - Devoxx 2014
Des maths et des recommandations - Devoxx 2014
Loïc Knuchel
 

Mehr von Loïc Knuchel (12)

Scala bad practices, scala.io 2019
Scala bad practices, scala.io 2019Scala bad practices, scala.io 2019
Scala bad practices, scala.io 2019
 
Mutation testing, enfin une bonne mesure de la qualité des tests ?, RivieraDe...
Mutation testing, enfin une bonne mesure de la qualité des tests ?, RivieraDe...Mutation testing, enfin une bonne mesure de la qualité des tests ?, RivieraDe...
Mutation testing, enfin une bonne mesure de la qualité des tests ?, RivieraDe...
 
Comprendre la programmation fonctionnelle, Blend Web Mix le 02/11/2016
Comprendre la programmation fonctionnelle, Blend Web Mix le 02/11/2016Comprendre la programmation fonctionnelle, Blend Web Mix le 02/11/2016
Comprendre la programmation fonctionnelle, Blend Web Mix le 02/11/2016
 
FP is coming... le 19/05/2016
FP is coming... le 19/05/2016FP is coming... le 19/05/2016
FP is coming... le 19/05/2016
 
Programmation fonctionnelle en JavaScript
Programmation fonctionnelle en JavaScriptProgrammation fonctionnelle en JavaScript
Programmation fonctionnelle en JavaScript
 
Ionic Framework, L'avenir du mobile sera hybride, bdx.io le 16-10-2015
Ionic Framework, L'avenir du mobile sera hybride, bdx.io le 16-10-2015Ionic Framework, L'avenir du mobile sera hybride, bdx.io le 16-10-2015
Ionic Framework, L'avenir du mobile sera hybride, bdx.io le 16-10-2015
 
Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
Ionic, ce n'est pas que de l'UI, meetup PhoneGap le 25-05-2015
 
Le développement mobile hybride sort du bois, Ch'ti JUG le 15-04-2015
Le développement mobile hybride sort du bois, Ch'ti JUG le 15-04-2015Le développement mobile hybride sort du bois, Ch'ti JUG le 15-04-2015
Le développement mobile hybride sort du bois, Ch'ti JUG le 15-04-2015
 
Devoxx 2015, Atelier Ionic - 09/04/2015
Devoxx 2015, Atelier Ionic - 09/04/2015Devoxx 2015, Atelier Ionic - 09/04/2015
Devoxx 2015, Atelier Ionic - 09/04/2015
 
Devoxx 2015, ionic chat
Devoxx 2015, ionic chatDevoxx 2015, ionic chat
Devoxx 2015, ionic chat
 
Ionic HumanTalks - 11/03/2015
Ionic HumanTalks - 11/03/2015Ionic HumanTalks - 11/03/2015
Ionic HumanTalks - 11/03/2015
 
Des maths et des recommandations - Devoxx 2014
Des maths et des recommandations - Devoxx 2014Des maths et des recommandations - Devoxx 2014
Des maths et des recommandations - Devoxx 2014
 

Kürzlich hochgeladen

TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
%+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 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
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
VishalKumarJha10
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 

Kürzlich hochgeladen (20)

%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare%in Harare+277-882-255-28 abortion pills for sale in Harare
%in Harare+277-882-255-28 abortion pills for sale in Harare
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
 
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 Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durban%in Durban+277-882-255-28 abortion pills for sale in Durban
%in Durban+277-882-255-28 abortion pills for sale in Durban
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisions
 
%+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 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...
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
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
 
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdfPayment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
Payment Gateway Testing Simplified_ A Step-by-Step Guide for Beginners.pdf
 

Ionic2 - the raise of web developer, Riviera DEV le 17/06/2016

  • 1. The raise of web developers @loicknuchel
  • 2. ?
  • 3. Loïc Knuchel Geek passionné Freelance Développeur web full-stack Entrepreneur Cookers / SalooN loicknuchel@gmail.com @loicknuchel http://loic.knuchel.org/
  • 5. Juin 2007 Lancement de l’iPhone 1
  • 6. Septembre 2008 Sortie du HTC G1 avec Android
  • 7. ● Nouvelles possibilités ○ UX ○ Technique ○ Business ● Un écosystème à bâtir
  • 8. ● Nouvelle stack technique ● Peu de personnes formées ● Développer plusieurs fois la même chose ● Environnements très spécifiques (offline, puissance, versions, diversité...)
  • 9.
  • 11. Idée Coder des applications entièrement dans la WebView Avantages : ● Technologies et environnements connus ● Cross-platform
  • 12. PhoneGap / Cordova Mars 2009 : Lancement de PhoneGap par Nitobi Octobre 2011 : Rachat de Nitobi par Adobe Séparation de la technologie (Cordova) et des services commerciaux (PhoneGap)
  • 13.
  • 14. Oups... ● UI moche ● UI peu réactive ● loin du look & feel natif Mauvais support des standards du web dans la WebView Peu d’outils / librairies Téléphones peu puissants ● App de mauvaise qualité ● Bugs Souvent pour des projets à petit budget...
  • 15. Aujourd’hui ● Téléphones puissants (et de + en +) ● Très bon support des standards web dans la WebView ● Beaucoup d’outils / librairies
  • 16.
  • 18. Stack technologique Natif Web Téléphone & APIs natives Cordova : webview + JavaScript bridges Angular Ionic Application
  • 19. Dév web = Dév mobile
  • 20. DX “We want to cater to the 99% who just want to build something functional quickly and not break the bank to do it.” - Max Lynch
  • 21. DX #Platform continuity #CLI #Backend services #Push #Deploy #Package#Auth #Analytics #Ionic View #Native plugins #Ionic Market #Ionic Creator
  • 23. Ionic is a complete ecosystem !
  • 25. Hybrid apps have superpowers...
  • 27. App Store installs are broken ! ? http://bit.ly/voxxrin
  • 28. App Store installs are broken ! Deep linking Install tracking
  • 29. Hybrid superpowers Web App : ● Cross-platform ● Accès instantané ● Deep link ● Offline http://bit.ly/voxxrin-bdx-lkn
  • 30. Hybrid superpowers Web App : ● Cross-platform ● Accès instantané ● Deep link ● Offline Progressive Web App : ● Installation instantanée ● Lancement depuis la Home ● Push notifications
  • 31. Hybrid superpowers Web App : ● Cross-platform ● Accès instantané ● Deep link ● Offline Progressive Web App : ● Installation instantanée ● Lancement depuis la Home ● Push notifications Native App : ● Accès complet au téléphone
  • 33. App Store deployment is broken ! Apple : ~ 2 jours Google : ~ 2 heures
  • 35.
  • 36.
  • 37.
  • 38.
  • 39.
  • 40.
  • 41.
  • 42.
  • 43.
  • 44.
  • 45.
  • 46. Nouveautés depuis Ionic 1 ● Angular 2 (+ TypeScript) ● Navigation push/pop ● Nouveaux composants ○ DateTime ○ Toast ○ Searchbar ○ Segment
  • 47. Getting started Install nodejs & npm $ npm install -g ionic@beta $ ionic start demoApp --v2 --ts $ cd demoApp && ionic serve ♬ ♫ ♬ ♫ Your Ionic app is ready to go! ♬ ♫ ♬ ♫
  • 48. Getting started Install mobile sdk (Android ou iOS) $ sudo npm install -g cordova $ ionic platform add android $ ionic run android
  • 50. index.html <!DOCTYPE html> <html lang="en" dir="ltr"> <head> <meta charset="UTF-8"> <title>Ionic</title> <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"> <meta name="format-detection" content="telephone=no"> <meta name="msapplication-tap-highlight" content="no"> <link ios-href="build/css/app.ios.css" rel="stylesheet"> <link md-href="build/css/app.md.css" rel="stylesheet"> <link wp-href="build/css/app.wp.css" rel="stylesheet"> </head> <body> <!-- this Ionic's root component and where the app will load --> <ion-app></ion-app> <!-- cordova.js required for cordova apps --> <script src="cordova.js"></script> <!-- Polyfill needed for platforms without Promise and Collection support --> <script src="build/js/es6-shim.min.js"></script> <!-- Zone.js and Reflect-metadata --> <script src="build/js/Reflect.js"></script> <script src="build/js/zone.js"></script> <!-- the bundle which is built from the app's source code --> <script src="build/js/app.bundle.js"></script> </body> </html>
  • 51. app.ts import {App, Platform} from 'ionic-angular'; import {StatusBar} from 'ionic-native'; import {TabsPage} from './pages/tabs/tabs'; @App({ template: '<ion-nav [root]="rootPage"></ion-nav>', config: {} // http://ionicframework.com/docs/v2/api/config/Config/ }) export class MyApp { rootPage: any = TabsPage; constructor(platform: Platform) { platform.ready().then(() => { // Okay, so the platform is ready and our plugins are available. // Here you can do any higher level native things you might need. StatusBar.styleDefault(); }); } }
  • 52. page1.ts import {Page} from 'ionic-angular'; @Page({ templateUrl: 'build/pages/page1/page1.html' }) export class Page1 { constructor() { } } <ion-navbar *navbar> <ion-title>Tab 1</ion-title> </ion-navbar> <ion-content padding class="page1"> <h2>Welcome to Ionic!</h2> <p> This starter project comes with simple tabs-based layout for apps that are going to primarily use a Tabbed UI. </p> <p> Take a look at the <code>app/</code> directory to add or change tabs, update any existing page or create new pages. </p> </ion-content>
  • 53. page1.ts import {Page} from 'ionic-angular'; @Page({ template: ` <ion-navbar *navbar> <ion-title>Tab 1</ion-title> </ion-navbar> <ion-content padding class="page1"> <h2>Welcome to Ionic!</h2> <p> This starter project comes with simple tabs-based layout for apps that are going to primarily use a Tabbed UI. </p> </ion-content>` }) export class Page1 { constructor() {} }
  • 54. page1.ts import {Page} from 'ionic-angular'; @Page({ styles: [` .page1 h2 { color: red; } `], template: `...` }) export class Page1 { constructor() {} }
  • 55. Angular 1 vs Angular 2 ● bootstrap manuel ● Filter => Pipe ● Controllers => Components ● Directives => Components ● $scope => Class properties ● Services => Injectables
  • 56. Template ● Bindings : ● Pipes : ● Propriétés / Input : ● Evénements / Output : ● Double binding : ● Templates : ● Local variables : ● Boucles : Your favorite hero is: {{favoriteHero}} <span>{{movie.title | uppercase}}</span> <a [href]="angularDocsUrl">Angular Docs</a> <button (click)="toggleMovie()"></button> <input [(ngModel)]="favoriteMovie" /> <div *ngIf="movies.length === 0">No movies</div> <video-player #player></video-player> <button (click)="player.pause()">Pause</button> <ul *ngFor="let movie of movies"> <li>{{movie.title}}</li> </ul>
  • 57.
  • 59. todo.page.ts todo.html todo.scss import {Page} from 'ionic-angular'; @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { constructor() { } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-content class="todo-page"> </ion-content> .todo-page { .done { text-decoration: line-through; } }
  • 60. import {App, Platform} from 'ionic-angular'; import {StatusBar} from 'ionic-native'; import {TabsPage} from './pages/tabs/tabs'; import {TodoPage} from "./pages/todo/todo.page"; @App({ template: '<ion-nav [root]="rootPage"></ion-nav>', config: {} }) export class MyApp { rootPage: any = TodoPage; constructor(platform: Platform) { platform.ready().then(() => { StatusBar.styleDefault(); }); } } // http://ionicframework.com/docs/v2/theming/ // App Shared Imports // -------------------------------------------------- // These are the imports which make up the design of this app. // By default each design mode includes these shared imports. // App Shared Sass variables belong in app.variables. scss. @import "../pages/page1/page1"; @import "../pages/page2/page2"; @import "../pages/page3/page3"; @import "../pages/todo/todo"; app.ts theme/app.core.scss
  • 61. Ionic2 TODO list import {Page} from 'ionic-angular'; class Todo { constructor( public name: string, public done: boolean = false ) {} } @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { constructor() { } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-content class="todo-page"> </ion-content>
  • 62. Ionic2 TODO list import {Page} from 'ionic-angular'; class Todo { constructor( public name: string, public done: boolean = false ) {} } @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { todos: Todo[] = [ new Todo('todo 1'), new Todo('todo 2'), new Todo('todo 3') ]; constructor() { } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-content class="todo-page"> </ion-content>
  • 63. Ionic2 TODO list <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-content class="todo-page"> <ion-list> <ion-item *ngFor="let todo of todos" [hidden]="todo.done"> <ion-label>{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done"></ion-checkbox> </ion-item> <ion-item *ngFor="let todo of todos" [hidden]="!todo.done"> <ion-label class="done">{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox> </ion-item> </ion-list> </ion-content>
  • 64. Ionic2 TODO list import {Page} from 'ionic-angular'; @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { newTodo: string = ''; todos: Todo[] = [ new Todo('todo 1'), new Todo('todo 2'), new Todo('todo 3') ]; constructor() { } create(text: string): void { this.todos.push(new Todo(text)); this.newTodo = ''; } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-toolbar> <ion-input type="text" [(ngModel)]="newTodo" placeholder="Nouvelle tâche"> </ion-input> <ion-buttons end> <button (click)="create(newTodo)"> <ion-icon name="send"></ion-icon> </button> </ion-buttons> </ion-toolbar> <ion-content class="todo-page"> <ion-list> ... </ion-list> </ion-content>
  • 65. Ionic2 TODO list import {Page} from 'ionic-angular'; @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { newTodo: string = ''; todos: Todo[] = [...]; constructor() { } create(text: string): void { ... } delete(todo: Todo): void { const i = this.todos.indexOf(todo); if(i >= 0) { this.todos.splice(i, 1); } } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-toolbar> ... </ion-toolbar> <ion-content class="todo-page"> <ion-list> <ion-item *ngFor="let todo of todos" [hidden]="todo.done"> <ion-label>{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done"></ion-checkbox> </ion-item> <ion-item *ngFor="..." [hidden]="!todo.done" (click)="delete(todo)"> <ion-label class="done">{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox> </ion-item> </ion-list> </ion-content>
  • 66. Ionic2 TODO list import {Page} from 'ionic-angular'; @Page({ templateUrl: 'build/pages/todo/todo.html' }) export class TodoPage { newTodo: string = ''; todos: Todo[] = [...]; constructor() { } create(text: string): void { ... } delete(todo: Todo): void { const i = this.todos.indexOf(todo); if(i >= 0) { this.todos.splice(i, 1); } } } <ion-navbar *navbar> <ion-title>Todos</ion-title> </ion-navbar> <ion-toolbar> ... </ion-toolbar> <ion-content class="todo-page"> <ion-list> <ion-item *ngFor="let todo of todos" [hidden]="todo.done"> <ion-label>{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done"></ion-checkbox> </ion-item> <ion-item *ngFor="..." [hidden]="!todo.done" (click)="delete(todo)"> <ion-label class="done">{{todo.name}}</ion-label> <ion-checkbox [(ngModel)]="todo.done" disabled="true"></ion-checkbox> </ion-item> </ion-list> </ion-content>
  • 67.
  • 68. Pour tester ce weekend...
  • 69. Pour tester ce weekend... http://ionicframework.com/docs/v2/ https://github.com/driftyco/ionic-conference-app https://github.com/saloonapp/saloon-app http://mcgivery.com/15-ionic-framework-2-resources/ (60+ maintenant…) https://angular.io/docs/ts/latest/cookbook/ https://forum.ionicframework.com/ http://loic.knuchel.org/blog/
  • 70.