forked from barryclark/jekyll-now
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
2661 lines (1323 loc) · 75.6 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html class="theme-next gemini use-motion" lang="en">
<head>
<meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
<meta name="theme-color" content="#222">
<script src="/lib/pace/pace.min.js?v=1.0.2"></script>
<link href="/lib/pace/pace-theme-minimal.min.css?v=1.0.2" rel="stylesheet">
<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<link href="/lib/fancybox/source/jquery.fancybox.css?v=2.1.5" rel="stylesheet" type="text/css" />
<link href="/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css" />
<link href="/css/main.css?v=5.1.3" rel="stylesheet" type="text/css" />
<link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon-next.png?v=5.1.3">
<link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32-next.png?v=5.1.3">
<link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16-next.png?v=5.1.3">
<link rel="mask-icon" href="/images/logo.svg?v=5.1.3" color="#222">
<meta name="keywords" content="Hexo, NexT" />
<meta property="og:type" content="website">
<meta property="og:title" content="FRONT.DEV.MK">
<meta property="og:url" content="http://mkfdev.github.io/index.html">
<meta property="og:site_name" content="FRONT.DEV.MK">
<meta property="og:locale" content="en">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="FRONT.DEV.MK">
<script type="text/javascript" id="hexo.configurations">
var NexT = window.NexT || {};
var CONFIG = {
root: '/',
scheme: 'Gemini',
version: '5.1.3',
sidebar: {"position":"left","display":"post","offset":12,"b2t":false,"scrollpercent":false,"onmobile":false},
fancybox: true,
tabs: true,
motion: {"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}},
duoshuo: {
userId: '0',
author: 'Author'
},
algolia: {
applicationID: '',
apiKey: '',
indexName: '',
hits: {"per_page":10},
labels: {"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}
}
};
</script>
<link rel="canonical" href="http://mkfdev.github.io/"/>
<title>FRONT.DEV.MK</title>
</head>
<body itemscope itemtype="http://schema.org/WebPage" lang="en">
<div class="container sidebar-position-left
page-home">
<div class="headband"></div>
<header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
<div class="header-inner"><div class="site-brand-wrapper">
<div class="site-meta ">
<div class="custom-logo-site-title">
<a href="/" class="brand" rel="start">
<span class="logo-line-before"><i></i></span>
<span class="site-title">FRONT.DEV.MK</span>
<span class="logo-line-after"><i></i></span>
</a>
</div>
<h1 class="site-subtitle" itemprop="description"></h1>
</div>
<div class="site-nav-toggle">
<button>
<span class="btn-bar"></span>
<span class="btn-bar"></span>
<span class="btn-bar"></span>
</button>
</div>
</div>
<nav class="site-nav">
<ul id="menu" class="menu">
<li class="menu-item menu-item-home">
<a href="/" rel="section">
<i class="menu-item-icon fa fa-fw fa-home"></i> <br />
Home
</a>
</li>
<li class="menu-item menu-item-categories">
<a href="/categories/" rel="section">
<i class="menu-item-icon fa fa-fw fa-th"></i> <br />
Categories
</a>
</li>
<li class="menu-item menu-item-archives">
<a href="/archives/" rel="section">
<i class="menu-item-icon fa fa-fw fa-archive"></i> <br />
Archives
</a>
</li>
<li class="menu-item menu-item-search">
<a href="javascript:;" class="popup-trigger">
<i class="menu-item-icon fa fa-search fa-fw"></i> <br />
Search
</a>
</li>
</ul>
<div class="site-search">
<div class="popup search-popup local-search-popup">
<div class="local-search-header clearfix">
<span class="search-icon">
<i class="fa fa-search"></i>
</span>
<span class="popup-btn-close">
<i class="fa fa-times-circle"></i>
</span>
<div class="local-search-input-wrapper">
<input autocomplete="off"
placeholder="Searching..." spellcheck="false"
type="text" id="local-search-input">
</div>
</div>
<div id="local-search-result"></div>
</div>
</div>
</nav>
</div>
</header>
<main id="main" class="main">
<div class="main-inner">
<div class="content-wrap">
<div id="content" class="content">
<section id="posts" class="posts-expand">
<article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
<div class="post-block">
<link itemprop="mainEntityOfPage" href="http://mkfdev.github.io/2017/11/21/TIL-1121/">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" content="Min Kyung">
<meta itemprop="description" content="">
<meta itemprop="image" content="/images/avatar.gif">
</span>
<span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="FRONT.DEV.MK">
</span>
<header class="post-header">
<h2 class="post-title" itemprop="name headline">
<a class="post-title-link" href="/2017/11/21/TIL-1121/" itemprop="url">Angular2 form 유효성 검증</a></h2>
<div class="post-meta">
<span class="post-time">
<span class="post-meta-item-icon">
<i class="fa fa-calendar-o"></i>
</span>
<span class="post-meta-item-text">Posted on</span>
<time title="Post created" itemprop="dateCreated datePublished" datetime="2017-11-21T19:26:40+09:00">
2017-11-21
</time>
</span>
<span class="post-category" >
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-folder-o"></i>
</span>
<span class="post-meta-item-text">In</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="/categories/TIL/" itemprop="url" rel="index">
<span itemprop="name">TIL</span>
</a>
</span>
</span>
<span class="post-comments-count">
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-comment-o"></i>
</span>
<a href="/2017/11/21/TIL-1121/#comments" itemprop="discussionUrl">
<span class="post-comments-count ds-thread-count" data-thread-key="2017/11/21/TIL-1121/" itemprop="commentCount"></span>
</a>
</span>
</div>
</header>
<div class="post-body" itemprop="articleBody">
<h2 id="form-submit"><a href="#form-submit" class="headerlink" title="form - submit"></a>form - submit</h2><ul>
<li>서버에 전송. </li>
<li>페이지 전환(깜박거림).</li>
<li>form안의 요소들(그룹)이 하나라도 유효하지 않으면 전송할 수 없다.</li>
</ul>
<h2 id="form-control"><a href="#form-control" class="headerlink" title="form control"></a>form control</h2><ul>
<li>name 어트리뷰트가 데이터의 이름이 된다.</li>
<li>ngModel을 써줘야 control이 만들어짐</li>
<li>각각의 input에 접근하기 위해서는 form 참조 변수를 사용한다.</li>
<li>ex) userForm.value (참조변수:#userForm)</li>
<li>#name=”ngModel”: 유효성 검증 상태 추적이 가능해진다.</li>
</ul>
<h2 id="템플릿-기반-폼-유효성-검증-AbstractControl클래스"><a href="#템플릿-기반-폼-유효성-검증-AbstractControl클래스" class="headerlink" title="템플릿 기반 폼 유효성 검증 - AbstractControl클래스"></a>템플릿 기반 폼 유효성 검증 - AbstractControl클래스</h2><ul>
<li>유효성 검증의 상태를 나타내는 프로퍼티를 가지고 있음</li>
<li>errors, invalid, valid, pristine, undouched, dirty 등</li>
<li>untouched: fousin -> focusout되면 false</li>
<li>pristine: 값이 한번이라도 입력된 상태 false</li>
<li>*ngIf를 사용해서 에러메시지를 출력하는게 좋다 -> 조건에 부합하면 DOM에서 사라지기 때문</li>
<li>에러메시지는 값을 입력하고 focusout됐을 때 출력되야 함.</li>
<li>errors => invalid: true, untouched: false</li>
</ul>
<h2 id="리액티브폼-컴포넌트-기반"><a href="#리액티브폼-컴포넌트-기반" class="headerlink" title="리액티브폼 - 컴포넌트 기반"></a>리액티브폼 - 컴포넌트 기반</h2><ul>
<li>템플릿 기반보다 복잡할 경우 사용. (form이 15개 이상이거나 많은 검증이 필요할때)</li>
<li>컴포넌트 기반</li>
<li>formControlName이 템플릿기반 폼에서 name의 역할을 한다.</li>
</ul>
</div>
<footer class="post-footer">
<div class="post-eof"></div>
</footer>
</div>
</article>
<article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
<div class="post-block">
<link itemprop="mainEntityOfPage" href="http://mkfdev.github.io/2017/11/13/TIL-1113/">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" content="Min Kyung">
<meta itemprop="description" content="">
<meta itemprop="image" content="/images/avatar.gif">
</span>
<span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="FRONT.DEV.MK">
</span>
<header class="post-header">
<h2 class="post-title" itemprop="name headline">
<a class="post-title-link" href="/2017/11/13/TIL-1113/" itemprop="url">angular2 CLI 커맨드 정리</a></h2>
<div class="post-meta">
<span class="post-time">
<span class="post-meta-item-icon">
<i class="fa fa-calendar-o"></i>
</span>
<span class="post-meta-item-text">Posted on</span>
<time title="Post created" itemprop="dateCreated datePublished" datetime="2017-11-13T20:22:50+09:00">
2017-11-13
</time>
</span>
<span class="post-category" >
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-folder-o"></i>
</span>
<span class="post-meta-item-text">In</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="/categories/TIL/" itemprop="url" rel="index">
<span itemprop="name">TIL</span>
</a>
</span>
</span>
<span class="post-comments-count">
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-comment-o"></i>
</span>
<a href="/2017/11/13/TIL-1113/#comments" itemprop="discussionUrl">
<span class="post-comments-count ds-thread-count" data-thread-key="2017/11/13/TIL-1113/" itemprop="commentCount"></span>
</a>
</span>
</div>
</header>
<div class="post-body" itemprop="articleBody">
<h1 id="Angular-CLI-커맨드-정리"><a href="#Angular-CLI-커맨드-정리" class="headerlink" title="Angular CLI 커맨드 정리"></a>Angular CLI 커맨드 정리</h1><h2 id="Angular-CLI-설치"><a href="#Angular-CLI-설치" class="headerlink" title="Angular CLI 설치"></a>Angular CLI 설치</h2><ul>
<li>npm install -g angular-cli</li>
</ul>
<h2 id="프로젝트-생성"><a href="#프로젝트-생성" class="headerlink" title="프로젝트 생성"></a>프로젝트 생성</h2><ul>
<li>ng new 프로젝트명</li>
</ul>
<h2 id="포트변경"><a href="#포트변경" class="headerlink" title="포트변경"></a>포트변경</h2><p>ng serve -port 4001</p>
<h2 id="구성요소-추가"><a href="#구성요소-추가" class="headerlink" title="구성요소 추가"></a>구성요소 추가</h2><h3 id="컴포넌트-추가"><a href="#컴포넌트-추가" class="headerlink" title="컴포넌트 추가"></a>컴포넌트 추가</h3><ul>
<li>ng g c 컴포넌트명</li>
</ul>
<h3 id="디렉티브-추가"><a href="#디렉티브-추가" class="headerlink" title="디렉티브 추가"></a>디렉티브 추가</h3><ul>
<li>ng g d 디렉티브명</li>
</ul>
<h3 id="파이프-추가"><a href="#파이프-추가" class="headerlink" title="파이프 추가"></a>파이프 추가</h3><ul>
<li>ng g p 파이프명</li>
</ul>
<h3 id="서비스-추가"><a href="#서비스-추가" class="headerlink" title="서비스 추가"></a>서비스 추가</h3><p>*ng g s 서비스명</p>
<h2 id="빌드-및-실행"><a href="#빌드-및-실행" class="headerlink" title="빌드 및 실행"></a>빌드 및 실행</h2><h3 id="개발-서버-실행"><a href="#개발-서버-실행" class="headerlink" title="개발 서버 실행"></a>개발 서버 실행</h3><ul>
<li>ng serve</li>
</ul>
<h3 id="개발-서버-실행-watch"><a href="#개발-서버-실행-watch" class="headerlink" title="개발 서버 실행(watch)"></a>개발 서버 실행(watch)</h3><ul>
<li>ng serve -o</li>
</ul>
<h3 id="빌드"><a href="#빌드" class="headerlink" title="빌드"></a>빌드</h3><ul>
<li>ng build</li>
</ul>
</div>
<footer class="post-footer">
<div class="post-eof"></div>
</footer>
</div>
</article>
<article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
<div class="post-block">
<link itemprop="mainEntityOfPage" href="http://mkfdev.github.io/2017/11/09/TIL-1109/">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" content="Min Kyung">
<meta itemprop="description" content="">
<meta itemprop="image" content="/images/avatar.gif">
</span>
<span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="FRONT.DEV.MK">
</span>
<header class="post-header">
<h2 class="post-title" itemprop="name headline">
<a class="post-title-link" href="/2017/11/09/TIL-1109/" itemprop="url">Angular2 문법과 MVC패턴</a></h2>
<div class="post-meta">
<span class="post-time">
<span class="post-meta-item-icon">
<i class="fa fa-calendar-o"></i>
</span>
<span class="post-meta-item-text">Posted on</span>
<time title="Post created" itemprop="dateCreated datePublished" datetime="2017-11-09T21:21:05+09:00">
2017-11-09
</time>
</span>
<span class="post-category" >
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-folder-o"></i>
</span>
<span class="post-meta-item-text">In</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="/categories/TIL/" itemprop="url" rel="index">
<span itemprop="name">TIL</span>
</a>
</span>
</span>
<span class="post-comments-count">
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-comment-o"></i>
</span>
<a href="/2017/11/09/TIL-1109/#comments" itemprop="discussionUrl">
<span class="post-comments-count ds-thread-count" data-thread-key="2017/11/09/TIL-1109/" itemprop="commentCount"></span>
</a>
</span>
</div>
</header>
<div class="post-body" itemprop="articleBody">
<h2 id="Angular-형식"><a href="#Angular-형식" class="headerlink" title="Angular 형식"></a>Angular 형식</h2><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br></pre></td><td class="code"><pre><span class="line">import {...} from '@angular/core';</span><br><span class="line">//데코레이터</span><br><span class="line">@Complate({</span><br><span class="line"> selector:...,</span><br><span class="line"> template:...,</span><br><span class="line"> styles:...</span><br><span class="line">})</span><br><span class="line">export class AppComponent{</span><br><span class="line"> name:String; //template과 연동</span><br><span class="line">}</span><br></pre></td></tr></table></figure>
<h2 id="Angular에서-뷰-템플릿-변경"><a href="#Angular에서-뷰-템플릿-변경" class="headerlink" title="Angular에서 뷰(템플릿) 변경"></a>Angular에서 뷰(템플릿) 변경</h2><p>앵귤러가없으면 DOM API를 이용해서 데이터를 변경한다.<br>그러나 앵귤러에서는 DOM API를 쓰지 않고 컴포넌트 클래스 내에 데이터를 갖고 있으면 Data Binding로직에 의해서 template syntax에 표시하여 변경한다.(인터폴레이션)<br>** 앞으로 배울것 Data binding</p>
<h2 id="Data-binding"><a href="#Data-binding" class="headerlink" title="Data binding"></a>Data binding</h2><ul>
<li>DOM API 접근 방식: javascript는 DOM에 강하게 의존하고 있다(조작하고 있는 view태그를 변경하면 자바스크립트를 변경해야 한다.)</li>
<li>Angular는 템플릿(html)이 컴포넌트 클래스(javascript)의 데이터를 인터폴레이션이 가져가도록 작동한다.</li>
<li>따라서 템플릿에서 태그를 변경해도 영향을 미치지 않는다 => 템플릿이 주도권을 가짐</li>
<li>인터폴레이션 : { { title } }</li>
</ul>
<!--noindex-->
<div class="post-button text-center">
<a class="btn" href="/2017/11/09/TIL-1109/#more" rel="contents">
Read more »
</a>
</div>
<!--/noindex-->
</div>
<footer class="post-footer">
<div class="post-eof"></div>
</footer>
</div>
</article>
<article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
<div class="post-block">
<link itemprop="mainEntityOfPage" href="http://mkfdev.github.io/2017/11/07/TIL-1107/">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" content="Min Kyung">
<meta itemprop="description" content="">
<meta itemprop="image" content="/images/avatar.gif">
</span>
<span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="FRONT.DEV.MK">
</span>
<header class="post-header">
<h2 class="post-title" itemprop="name headline">
<a class="post-title-link" href="/2017/11/07/TIL-1107/" itemprop="url">Angular2 기본 개념과 구성</a></h2>
<div class="post-meta">
<span class="post-time">
<span class="post-meta-item-icon">
<i class="fa fa-calendar-o"></i>
</span>
<span class="post-meta-item-text">Posted on</span>
<time title="Post created" itemprop="dateCreated datePublished" datetime="2017-11-07T19:19:30+09:00">
2017-11-07
</time>
</span>
<span class="post-category" >
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-folder-o"></i>
</span>
<span class="post-meta-item-text">In</span>
<span itemprop="about" itemscope itemtype="http://schema.org/Thing">
<a href="/categories/TIL/" itemprop="url" rel="index">
<span itemprop="name">TIL</span>
</a>
</span>
</span>
<span class="post-comments-count">
<span class="post-meta-divider">|</span>
<span class="post-meta-item-icon">
<i class="fa fa-comment-o"></i>
</span>
<a href="/2017/11/07/TIL-1107/#comments" itemprop="discussionUrl">
<span class="post-comments-count ds-thread-count" data-thread-key="2017/11/07/TIL-1107/" itemprop="commentCount"></span>
</a>
</span>
</div>
</header>
<div class="post-body" itemprop="articleBody">
<h2 id="Angular-기본-개념-및-구성-정리"><a href="#Angular-기본-개념-및-구성-정리" class="headerlink" title="Angular 기본 개념 및 구성 정리"></a>Angular 기본 개념 및 구성 정리</h2><h3 id="Angular소개"><a href="#Angular소개" class="headerlink" title="Angular소개"></a>Angular소개</h3><ul>
<li>“Web Component”를 기반으로 프레임워크가 만들어짐</li>
<li>SPA(Single Page Application)개발을 위한 구글의 오픈소스 자바스크립트 프레임워크 </li>
<li>초기 로딩이 길다(SPA의 단점)</li>
<li>초기 로딩 이후의 화면전환이나 인터렉션은 빠르다.</li>
<li>AngularJS(v1,ES5) 2012년 구글의 미스코 헤브리가 공개. 지속적으로 업데이트를 진행하고 있다.</li>
<li>Angular(v2~, typescriprt) 2014년 ng컨퍼런스에서 처음으로 소개.</li>
<li>Angular는 AngularJS의 후속 버전이지만 호환성이 없다.</li>
<li>Angular에서는 자바스크립트 값이 html과 상호 연동된다.</li>
<li>하나 이상의 모듈과 컴포넌트가 존재해야 된다.</li>
<li>대부분의 모던 브라우저를 지원한다.(IE는 9이상)</li>
</ul>
<h3 id="Angular의-장점"><a href="#Angular의-장점" class="headerlink" title="Angular의 장점"></a>Angular의 장점</h3><p>1) 개선된 개발 생산성<br> 1) 컴포넌트 기반 개발<br> 2) Typescript의 도입</p>
<pre><code>- Typescript의 정적 타이핑/ ECMAScript6의 클래스,모듈/ ECMAScript7의 데코레이터를 지원한다.
3) 개발 도구의 통합 및 개발 환경 구축 자동화
- 설정해야 할 도구가 많고 설정 방법은 익숙지 않다. => Angular는 CLI을 통해 간편한 개발 환경 구축을 지원한다.(개발환경 구축에 소요되는 시간 최소화)
</code></pre><p>2) 성능 향상<br> 1) Digest Loop로 인한 성능저하 문제의 해결</p>
<pre><code>- AngularJS는 Model의 변화를 View에 반영시키는 과정(Digest Loog)로 인한 성능저하가 단점 (양방향 바인딩을 위해서는 watcher가 추가됨, watcher가 늘어날수록 성능 저하)
2) AoT 컴파일
- 사전 컴파일 방식을 의미. 런타임에서 실시하지 않고 사전에 컴파일하여 속도를 향상시키는 기법.
3) Lazy Loading
- 지연 로딩. SPA의 단점을 극복하기 위한 대안.
- 애플리케이션 실행 시점에 모든 모듈을 한꺼번에 로딩하지 않고 필요한 시점에 필요한 모듈만을 로딩하는 방식
4) 코드 최적화
</code></pre>
<!--noindex-->
<div class="post-button text-center">
<a class="btn" href="/2017/11/07/TIL-1107/#more" rel="contents">
Read more »
</a>
</div>
<!--/noindex-->
</div>
<footer class="post-footer">
<div class="post-eof"></div>
</footer>
</div>
</article>
<article class="post post-type-normal" itemscope itemtype="http://schema.org/Article">
<div class="post-block">
<link itemprop="mainEntityOfPage" href="http://mkfdev.github.io/2017/11/06/TIL-1106/">
<span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" content="Min Kyung">
<meta itemprop="description" content="">
<meta itemprop="image" content="/images/avatar.gif">
</span>
<span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="FRONT.DEV.MK">
</span>
<header class="post-header">
<h2 class="post-title" itemprop="name headline">
<a class="post-title-link" href="/2017/11/06/TIL-1106/" itemprop="url">Typescript 문법</a></h2>