Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Angular JS Introduction
Search
Dhyego Fernando
May 06, 2015
Technology
0
54
Angular JS Introduction
Slides for AngularJS Introduction talk presented by me.
Dhyego Fernando
May 06, 2015
Tweet
Share
More Decks by Dhyego Fernando
See All by Dhyego Fernando
Web Components with Polymer (extra Polymer 2.0)
dhyegofernando
0
47
Introduction to Angular 2
dhyegofernando
0
63
Modular Angular JS
dhyegofernando
0
35
Other Decks in Technology
See All in Technology
[VPoE Global Summit] サービスレベル目標による信頼性への投資最適化
satos
0
240
Copilot Studio ハンズオン - 生成オーケストレーションモード
tomoyasasakimskk
0
220
Implementing and Evaluating a High-Level Language with WasmGC and the Wasm Component Model: Scala’s Case
tanishiking
0
180
まだ間に合う! 2025年のhono/ssg事情
watany
3
650
ヘンリー会社紹介資料(エンジニア向け) / company deck for engineer
henryofficial
0
360
OTEPsで知るOpenTelemetryの未来 / Observability Conference Tokyo 2025
arthur1
0
190
デザインとエンジニアリングの架け橋を目指す OPTiMのデザインシステム「nucleus」の軌跡と広げ方
optim
0
110
Okta Identity Governanceで実現する最小権限の原則 / Implementing the Principle of Least Privilege with Okta Identity Governance
tatsumin39
0
170
個人でデジタル庁の デザインシステムをVue.jsで 作っている話
nishiharatsubasa
3
5k
CREが作る自己解決サイクルSlackワークフローに組み込んだAIによる社内ヘルプデスク改革 #cre_meetup
bengo4com
0
320
現場の壁を乗り越えて、 「計装注入」が拓く オブザーバビリティ / Beyond the Field Barriers: Instrumentation Injection and the Future of Observability
aoto
PRO
1
350
Biz職でもDifyでできる! 「触らないAIワークフロー」を実現する方法
igarashikana
7
3.3k
Featured
See All Featured
What's in a price? How to price your products and services
michaelherold
246
12k
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
A Modern Web Designer's Workflow
chriscoyier
697
190k
Embracing the Ebb and Flow
colly
88
4.9k
Facilitating Awesome Meetings
lara
57
6.6k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
30
2.9k
Making Projects Easy
brettharned
120
6.4k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
127
54k
How to train your dragon (web standard)
notwaldorf
97
6.3k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.5k
Agile that works and the tools we love
rasmusluckow
331
21k
Transcript
Introduction to
About me Full-stack dev @dhyegofernando
None
None
The beginning
http://web.archive.org/web/20050428014715/http://www.youtube.com/ 2005
None
SPA Single Page Application
None
“AngularJS: a kind of HTML extension.”
D D D
Data-binding Dependency Injection Directives
Data-binding
$('#input-name').on('change', function() { $('#greeting-name').text(this.value); }); #input-name #greeting-name
None
None
model module bootstrap template expression <div ng-app> <div> <label>Name:</label> <input
type="text" ng-model="yourName"> <hr> <h1>Hello {{yourName}}!</h1> </div> </div>
None
Dependency Injection
controller bootstrap <div ng-app="app" ng-controller="GreetingController"> <form ng-submit="greet()"> <input type="text" ng-model="name">
<button type="submit">Greet</button> </form> </div>
module application dependency injection ... service 3rd's module service angular.module('app',
['alerter']) .controller('GreetingController', function($scope, Alerter) { $scope.name = 'John Doe'; $scope.greet = function() { Alerter.show('Hello ' + $scope.name); }; }); angular.module('alerter', []) .factory('Alerter', function($window) { return { show: function(string) { $window.alert(string); } }; });
Directives
Tab Component
Non-semantic way bootstrap plugin element <div id="tab"> <ul class="tab-head"> <li><a
href="#content-1">Title 1</a></li> <li><a href="#content-2">Title 2</a></li> <li><a href="#content-3">Title 3</a></li> </ul> <div id="content-1" class="tab-content"> <p>Content 1 goes here</p> </div> <div id="content-2" class="tab-content"> <p>Content 2 goes here</p> </div> <div id="content-3" class="tab-content"> <p>Content 3 goes here</p> </div> </div> $('#tab').tab();
None
Semantic way directives bootstrap ... tab components <tabset> <tab heading="Title
1"> <p>Content 1 goes here</p> </tab> <tab heading="Title 2"> <p>Content 2 goes here</p> </tab> <tab heading="Title 3"> <p>Content 3 goes here</p> </tab> </tabset> angular.module('tab') .directive('tabset', function() { // ... }) .directive('tab', function() { // ... });
None
Hello {{ world }}
load angular script bootstrap application set model template <!DOCTYPE html>
<html lang="en" ng-app> <head> <meta charset="UTF-8"> <title>Hello World</title> </head> <body> <input type="text" ng-model="name"> <h1>Hello {{ name }}</h1> <script src="//ajax.googleapis.com/ajax/libs/angularjs/1.3.15/ angular.min.js"></script> </body> </html>
Some golden tips
Don't reinvent the wheel
...use 3rd's components ✓ nice documentation ✓ great tests suit
✓ maintained ✓ best practices
where to find components?
http://ngmodules.org/
http://bower.io/
how to use components?
install the component bower install --save angular-material load the component
scripts <link rel="stylesheet" href="angular-material.min.css" rel="stylesheet"> <script src="angular-material.min.js"></script> load the component module angular.module('app', ['ngMaterial']);
follow the style guide
https://github.com/johnpapa/angular-styleguide
write tests
http://karma-runner.github.io/
http://angular.github.io/protractor/
use generators
http://yeoman.io/
https://github.com/yeoman/generator-angular
putting it all together
https://github.com/dhyegofernando/shopping-list-app Shopping list app
keep learning
https://docs.angularjs.org/api
with videos
https://www.youtube.com/user/angularjs/
https://egghead.io/
with blogs
http://www.johnpapa.net/
http://briantford.com/
http://toddmotto.com/
with books
AngularJS - Up & Running
https://www.ng-book.com/
with tools
http://ng-inspector.org/
https://github.com/angular/angularjs-batarang
and more...
Angular 2
https://angular.io/
https://angular.io/docs/js/latest/quickstart.html
Questions ?
Now it's up to you
Thank you @dhyegofernando