All language subtitles for 2. For Loop

af Afrikaans
sq Albanian
am Amharic
ar Arabic
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bn Bengali
bs Bosnian
bg Bulgarian
ca Catalan
ceb Cebuano
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
en English
eo Esperanto
et Estonian
tl Filipino
fi Finnish
fr French Download
fy Frisian
gl Galician
ka Georgian
de German
el Greek
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
km Khmer
ko Korean
ku Kurdish (Kurmanji)
ky Kyrgyz
lo Lao
la Latin
lv Latvian
lt Lithuanian
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mn Mongolian
my Myanmar (Burmese)
ne Nepali
no Norwegian
ps Pashto
fa Persian
pl Polish
pt Portuguese
pa Punjabi
ro Romanian
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
st Sesotho
sn Shona
sd Sindhi
si Sinhala
sk Slovak
sl Slovenian
so Somali
es Spanish
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
te Telugu
th Thai
tr Turkish
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu
or Odia (Oriya)
rw Kinyarwanda
tk Turkmen
tt Tatar
ug Uyghur
Would you like to inspect the original subtitles? These are the user uploaded subtitles that are being translated: 1 00:00:00,420 --> 00:00:06,180 Hello, welcome back in the annual lecture in the previous while we have talked about the data, how 2 00:00:06,180 --> 00:00:11,550 you can specify the data in your component and how you can use it in your template. 3 00:00:12,420 --> 00:00:14,430 You know, this lecture will take a look on the items. 4 00:00:14,430 --> 00:00:19,500 We have created our menu items, which specifies that five objects. 5 00:00:19,980 --> 00:00:22,500 So what we want to do now, we want to display them. 6 00:00:23,220 --> 00:00:24,340 OK, let's begin. 7 00:00:25,740 --> 00:00:26,940 Let's see, I love Paris. 8 00:00:26,980 --> 00:00:29,460 You remember everybody's playing them down here, but it's not the goat. 9 00:00:29,460 --> 00:00:32,370 I will remove them, notify. 10 00:00:32,520 --> 00:00:36,690 Let's notice the data itself, menu items, as I told many times before. 11 00:00:36,780 --> 00:00:39,450 Just five objects specified text property. 12 00:00:39,450 --> 00:00:44,010 If it is a text we want to display, that's the main part we want to display in our template. 13 00:00:45,120 --> 00:00:47,040 OK, for this whatever you want to do. 14 00:00:47,070 --> 00:00:52,380 We would like to create only one element, so let's remove all of the remaining monsters. 15 00:00:52,380 --> 00:00:58,050 Leave here one element reporter register inside and what we want to do. 16 00:00:58,050 --> 00:01:05,100 We want to replicate it five times and to dynamically specify the value inside from your menu item. 17 00:01:05,340 --> 00:01:11,250 So what I want to display here is exactly this first element to the display home. 18 00:01:11,520 --> 00:01:17,580 The second element will display about that element will display fake you and so on and so on. 19 00:01:18,270 --> 00:01:18,610 OK. 20 00:01:18,750 --> 00:01:20,640 That's what I would like to achieve. 21 00:01:22,110 --> 00:01:26,580 And to hear a new term this term is called die or active. 22 00:01:28,490 --> 00:01:35,960 Directive directives are special attributes you can place on your elements, on your team elements. 23 00:01:36,260 --> 00:01:40,970 And with the help of them, you can manipulate the DOM document. 24 00:01:40,970 --> 00:01:47,750 Object model basically can manipulate as as you are entering your HTML the way you are entering your 25 00:01:47,930 --> 00:01:48,380 HTML. 26 00:01:49,370 --> 00:01:53,120 OK, so just a directive to keep in mind the special attributes you can place on the element. 27 00:01:54,050 --> 00:01:56,770 And if you're using one here, let's get you some spacing. 28 00:01:56,780 --> 00:01:59,070 Let's plays a class on their separate line. 29 00:01:59,120 --> 00:02:00,110 I will do it like this. 30 00:02:01,460 --> 00:02:07,800 OK, so we have only one element and able to use here directive called V Dash for like this. 31 00:02:08,330 --> 00:02:14,270 You can see right there is the element or a template block multiple times based on the source data. 32 00:02:15,770 --> 00:02:20,630 To the V4 will specify our source data menu items. 33 00:02:22,130 --> 00:02:26,600 That's good about it would like to also access the single item in the iteration. 34 00:02:26,960 --> 00:02:28,880 You can do it like this before menu items. 35 00:02:28,880 --> 00:02:33,950 You will specify the item as you want to call it, which will be the value you are iterating. 36 00:02:34,400 --> 00:02:37,250 Simply call it item in menu items. 37 00:02:39,190 --> 00:02:44,470 All right, guys, so this item will hold the value of your menu items so as you will be rendering the 38 00:02:44,470 --> 00:02:45,070 elements. 39 00:02:46,540 --> 00:02:54,070 In the first iteration, this volte text home will be an item in the second iteration of old text about 40 00:02:54,740 --> 00:02:56,720 will be the item and so on and so on. 41 00:02:57,250 --> 00:02:57,580 OK. 42 00:02:59,900 --> 00:03:01,850 OK, I can see the squiggly lines, we'll worry about them. 43 00:03:02,060 --> 00:03:03,590 It is just a noting that they are missing. 44 00:03:03,590 --> 00:03:07,190 Somebody requires proper required values to specify. 45 00:03:08,870 --> 00:03:09,260 OK. 46 00:03:09,500 --> 00:03:11,680 The other they're active here is called V. 47 00:03:11,690 --> 00:03:18,880 Bind V does bind like this, and we'll specify here a key like the V Bind column key and it will pass 48 00:03:18,890 --> 00:03:21,620 here key, which should be unique, unique value. 49 00:03:22,490 --> 00:03:24,020 It should be based on something unique. 50 00:03:25,320 --> 00:03:29,880 As in this case, we have only five items that they are holding, the texts or the unique value of each 51 00:03:29,880 --> 00:03:31,200 item is the text itself. 52 00:03:31,680 --> 00:03:36,570 OK, so as a key, we'll specify here item dot text. 53 00:03:37,630 --> 00:03:39,250 OK, and that's your key here. 54 00:03:39,880 --> 00:03:44,860 It's called DirecTV, and you're specifying the key as the value here. 55 00:03:45,730 --> 00:03:46,070 OK. 56 00:03:46,990 --> 00:03:51,850 Then they even understand DirecTV, as will be creating all the components that will be passing the 57 00:03:51,850 --> 00:03:53,950 values around you will see is very simple. 58 00:03:54,550 --> 00:03:55,720 Then another Obama. 59 00:03:57,150 --> 00:03:59,930 Delhi, which is the link that I would like to link to. 60 00:04:01,110 --> 00:04:07,220 Terrible Vida v bind a normal element as we have on the element evil does a v by a draft and now you 61 00:04:07,220 --> 00:04:09,050 can provide your value dynamically. 62 00:04:09,470 --> 00:04:11,600 So let's say the value will be here. 63 00:04:12,170 --> 00:04:14,330 Item Dot Link. 64 00:04:15,390 --> 00:04:21,300 As you see, we don't have any links here on the text that we cannot access the link because we don't 65 00:04:21,300 --> 00:04:23,430 have it, so let's specify on each item link. 66 00:04:24,570 --> 00:04:28,200 Let's see a link here will be linking to flesh on the empty path. 67 00:04:28,830 --> 00:04:29,550 Let's see a link. 68 00:04:29,550 --> 00:04:32,590 Here will be the value of this discussion about it. 69 00:04:32,730 --> 00:04:35,320 Let's say this will be a close link. 70 00:04:36,270 --> 00:04:44,150 There'll be slash if a Q same, continue without looking at energy star slash. 71 00:04:44,520 --> 00:04:45,230 Log in a. 72 00:04:47,030 --> 00:04:50,780 OK, and the last one, the link. 73 00:04:52,770 --> 00:04:53,580 Let's register. 74 00:04:55,930 --> 00:04:59,710 OK, perfect, so now let's save you, let's take a look here. 75 00:04:59,740 --> 00:05:06,040 It's planning because the are already specifying the bind to item link, but we have here also one more 76 00:05:06,040 --> 00:05:08,920 additional h drive, so they need to remove the additional Obama. 77 00:05:10,240 --> 00:05:13,030 OK, and as you're iterating, you have access to this item. 78 00:05:13,030 --> 00:05:17,470 As I mentioned, we need to display also this item inside of the element as we have how it could be 79 00:05:17,470 --> 00:05:19,990 for a home logging and so on. 80 00:05:19,990 --> 00:05:25,900 But now it is valuable to go from the item to text because we have access to it. 81 00:05:27,290 --> 00:05:32,360 Nobody will save it, hopefully everything should work for you, go to your browser and uh, yeah, 82 00:05:32,540 --> 00:05:38,650 you can see you can see here every item, but now dynamically rendered out and I can click on this and 83 00:05:38,660 --> 00:05:40,370 I will go to about page here. 84 00:05:40,370 --> 00:05:46,550 It's about you can see fake, useless logging slash register and everything is working as we as we want. 85 00:05:47,720 --> 00:05:48,140 OK, guys. 86 00:05:48,140 --> 00:05:53,210 So just to recapitulate more small parts here we are using here a V for directives. 87 00:05:53,210 --> 00:05:59,120 Directives are used for manipulation of your HDL, as in this case you can see instead of displaying 88 00:05:59,130 --> 00:06:06,710 one element be displayed five depending on the number of menu items in the V for the value of their 89 00:06:06,710 --> 00:06:07,610 menu item. 90 00:06:08,510 --> 00:06:13,880 This value these value are stored into the item variable in the duration of your for loop. 91 00:06:14,420 --> 00:06:15,530 You can access this item here. 92 00:06:15,530 --> 00:06:16,280 You can call it as you want. 93 00:06:16,280 --> 00:06:18,860 You can call it a file. 94 00:06:19,010 --> 00:06:23,930 You can you can call it how it doesn't even make sense, right? 95 00:06:24,230 --> 00:06:26,270 You can call it to my variable. 96 00:06:26,780 --> 00:06:28,370 OK, but then you need to change. 97 00:06:28,370 --> 00:06:29,720 These are the things you need to call. 98 00:06:29,750 --> 00:06:35,390 You need to access the text under your my variable and link under my variable link and so on here. 99 00:06:36,290 --> 00:06:38,690 But of course, in this case, should be menu, right? 100 00:06:39,320 --> 00:06:47,720 So let's actually just just item so that we are providing here another clarity binding kind of al-dhari 101 00:06:47,720 --> 00:06:54,410 coverage directive called V Bind, where we are passing the key value, which will be the item text, 102 00:06:54,530 --> 00:07:00,800 the text itself and the HIV test provider attribute as we had it before, but it will be dynamically 103 00:07:00,800 --> 00:07:04,970 accessed from there from the item link, which is telling here. 104 00:07:07,420 --> 00:07:13,090 As you notice, whenever you are providing directives, the quotation here you are not providing actual 105 00:07:13,090 --> 00:07:13,900 string of value. 106 00:07:14,800 --> 00:07:20,920 Here is not actually think value, but it's interpolated value value from the variable item value accessing 107 00:07:20,920 --> 00:07:21,820 the tax property. 108 00:07:22,270 --> 00:07:23,800 If you want to provide your old. 109 00:07:24,940 --> 00:07:29,950 Rob Stringer value additional set of the single brackets, and then you will probably like this, but 110 00:07:29,980 --> 00:07:36,460 you will see its error because of you for directive key should be should be unique. 111 00:07:36,620 --> 00:07:38,920 OK, OK. 112 00:07:38,950 --> 00:07:41,290 You can hear if you can provide us as that is. 113 00:07:43,430 --> 00:07:48,680 OK, but of course, we don't want to here, one string of will repeat for every item, but in every 114 00:07:48,680 --> 00:07:51,920 iteration we would like to get higher dynamic value from each item. 115 00:07:53,430 --> 00:07:59,220 OK, and the same with item text, another thing we can simplify here, since the directive are so heavily 116 00:07:59,220 --> 00:08:01,400 used, especially this one here binds. 117 00:08:01,740 --> 00:08:07,730 We don't need to specify actually bind the keyboard we can fight and we can simply specify here only 118 00:08:07,740 --> 00:08:14,490 column key and here column a trip and the View Jazz Villa automatically fill it up for you. 119 00:08:15,690 --> 00:08:20,160 OK, so we just need to specify your key and the age of it's much nicer to write it like this. 120 00:08:20,550 --> 00:08:21,360 We can save it. 121 00:08:22,500 --> 00:08:25,710 We can go back here and refresh and everything will work as before. 122 00:08:26,340 --> 00:08:26,460 So. 123 00:08:26,880 --> 00:08:33,230 That's how did you create V for how you can create iterations in our time in your template to render 124 00:08:33,280 --> 00:08:39,060 multiple items and the questions we keep asking, and I hope to see you in the next lecture. 125 00:08:39,570 --> 00:08:40,440 Thank you for watching. 126 00:08:40,590 --> 00:08:41,010 Cheers. 12272

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.