├── .gitignore ├── 1-getting-started └── code │ ├── 1-first-app.html │ ├── 2-attribute-bind.html │ ├── 3-class-bind.html │ ├── README.md │ ├── images │ └── sammy-bath.png │ ├── index.css │ └── index.html ├── 2-logic ├── README.md └── code │ ├── 1-conditional.html │ ├── 2-loops.html │ ├── index.css │ └── index.html ├── 3-forms-events ├── README.md └── code │ ├── index-computed.html │ ├── index-computed.html:Zone.Identifier │ ├── index-computed.js │ ├── index-computed.js:Zone.Identifier │ ├── index-event.html │ ├── index-event.html:Zone.Identifier │ ├── index-event.js │ ├── index-event.js:Zone.Identifier │ ├── index-form-submit.html │ ├── index-form-submit.html:Zone.Identifier │ ├── index-form-submit.js │ ├── index-form-submit.js:Zone.Identifier │ ├── index-form-validation.html │ ├── index-form-validation.html:Zone.Identifier │ ├── index-form-validation.js │ ├── index-form-validation.js:Zone.Identifier │ ├── index-input.html │ ├── index-input.html:Zone.Identifier │ ├── index-input.js │ └── index-input.js:Zone.Identifier ├── 4-cli-components ├── README.md └── code │ ├── .DS_Store │ ├── .browserslistrc │ ├── README.md │ ├── package.json │ ├── public │ ├── favicon.ico │ └── index.html │ └── src │ ├── assets │ └── logo.png │ ├── components │ ├── BookingForm.vue │ ├── BookingList.vue │ └── Host.vue │ └── main.js ├── CODE_OF_CONDUCT.md ├── LICENSE ├── README.md └── SECURITY.md /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.rsuser 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Mono auto generated files 17 | mono_crash.* 18 | 19 | # Build results 20 | [Dd]ebug/ 21 | [Dd]ebugPublic/ 22 | [Rr]elease/ 23 | [Rr]eleases/ 24 | x64/ 25 | x86/ 26 | [Aa][Rr][Mm]/ 27 | [Aa][Rr][Mm]64/ 28 | bld/ 29 | [Bb]in/ 30 | [Oo]bj/ 31 | [Ll]og/ 32 | [Ll]ogs/ 33 | 34 | # Visual Studio 2015/2017 cache/options directory 35 | .vs/ 36 | # Uncomment if you have tasks that create the project's static files in wwwroot 37 | #wwwroot/ 38 | 39 | # Visual Studio 2017 auto generated files 40 | Generated\ Files/ 41 | 42 | # MSTest test Results 43 | [Tt]est[Rr]esult*/ 44 | [Bb]uild[Ll]og.* 45 | 46 | # NUnit 47 | *.VisualState.xml 48 | TestResult.xml 49 | nunit-*.xml 50 | 51 | # Build Results of an ATL Project 52 | [Dd]ebugPS/ 53 | [Rr]eleasePS/ 54 | dlldata.c 55 | 56 | # Benchmark Results 57 | BenchmarkDotNet.Artifacts/ 58 | 59 | # .NET Core 60 | project.lock.json 61 | project.fragment.lock.json 62 | artifacts/ 63 | 64 | # StyleCop 65 | StyleCopReport.xml 66 | 67 | # Files built by Visual Studio 68 | *_i.c 69 | *_p.c 70 | *_h.h 71 | *.ilk 72 | *.meta 73 | *.obj 74 | *.iobj 75 | *.pch 76 | *.pdb 77 | *.ipdb 78 | *.pgc 79 | *.pgd 80 | *.rsp 81 | *.sbr 82 | *.tlb 83 | *.tli 84 | *.tlh 85 | *.tmp 86 | *.tmp_proj 87 | *_wpftmp.csproj 88 | *.log 89 | *.vspscc 90 | *.vssscc 91 | .builds 92 | *.pidb 93 | *.svclog 94 | *.scc 95 | 96 | # Chutzpah Test files 97 | _Chutzpah* 98 | 99 | # Visual C++ cache files 100 | ipch/ 101 | *.aps 102 | *.ncb 103 | *.opendb 104 | *.opensdf 105 | *.sdf 106 | *.cachefile 107 | *.VC.db 108 | *.VC.VC.opendb 109 | 110 | # Visual Studio profiler 111 | *.psess 112 | *.vsp 113 | *.vspx 114 | *.sap 115 | 116 | # Visual Studio Trace Files 117 | *.e2e 118 | 119 | # TFS 2012 Local Workspace 120 | $tf/ 121 | 122 | # Guidance Automation Toolkit 123 | *.gpState 124 | 125 | # ReSharper is a .NET coding add-in 126 | _ReSharper*/ 127 | *.[Rr]e[Ss]harper 128 | *.DotSettings.user 129 | 130 | # TeamCity is a build add-in 131 | _TeamCity* 132 | 133 | # DotCover is a Code Coverage Tool 134 | *.dotCover 135 | 136 | # AxoCover is a Code Coverage Tool 137 | .axoCover/* 138 | !.axoCover/settings.json 139 | 140 | # Visual Studio code coverage results 141 | *.coverage 142 | *.coveragexml 143 | 144 | # NCrunch 145 | _NCrunch_* 146 | .*crunch*.local.xml 147 | nCrunchTemp_* 148 | 149 | # MightyMoose 150 | *.mm.* 151 | AutoTest.Net/ 152 | 153 | # Web workbench (sass) 154 | .sass-cache/ 155 | 156 | # Installshield output folder 157 | [Ee]xpress/ 158 | 159 | # DocProject is a documentation generator add-in 160 | DocProject/buildhelp/ 161 | DocProject/Help/*.HxT 162 | DocProject/Help/*.HxC 163 | DocProject/Help/*.hhc 164 | DocProject/Help/*.hhk 165 | DocProject/Help/*.hhp 166 | DocProject/Help/Html2 167 | DocProject/Help/html 168 | 169 | # Click-Once directory 170 | publish/ 171 | 172 | # Publish Web Output 173 | *.[Pp]ublish.xml 174 | *.azurePubxml 175 | # Note: Comment the next line if you want to checkin your web deploy settings, 176 | # but database connection strings (with potential passwords) will be unencrypted 177 | *.pubxml 178 | *.publishproj 179 | 180 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 181 | # checkin your Azure Web App publish settings, but sensitive information contained 182 | # in these scripts will be unencrypted 183 | PublishScripts/ 184 | 185 | # NuGet Packages 186 | *.nupkg 187 | # NuGet Symbol Packages 188 | *.snupkg 189 | # The packages folder can be ignored because of Package Restore 190 | **/[Pp]ackages/* 191 | # except build/, which is used as an MSBuild target. 192 | !**/[Pp]ackages/build/ 193 | # Uncomment if necessary however generally it will be regenerated when needed 194 | #!**/[Pp]ackages/repositories.config 195 | # NuGet v3's project.json files produces more ignorable files 196 | *.nuget.props 197 | *.nuget.targets 198 | 199 | # Microsoft Azure Build Output 200 | csx/ 201 | *.build.csdef 202 | 203 | # Microsoft Azure Emulator 204 | ecf/ 205 | rcf/ 206 | 207 | # Windows Store app package directories and files 208 | AppPackages/ 209 | BundleArtifacts/ 210 | Package.StoreAssociation.xml 211 | _pkginfo.txt 212 | *.appx 213 | *.appxbundle 214 | *.appxupload 215 | 216 | # Visual Studio cache files 217 | # files ending in .cache can be ignored 218 | *.[Cc]ache 219 | # but keep track of directories ending in .cache 220 | !?*.[Cc]ache/ 221 | 222 | # Others 223 | ClientBin/ 224 | ~$* 225 | *~ 226 | *.dbmdl 227 | *.dbproj.schemaview 228 | *.jfm 229 | *.pfx 230 | *.publishsettings 231 | orleans.codegen.cs 232 | 233 | # Including strong name files can present a security risk 234 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 235 | #*.snk 236 | 237 | # Since there are multiple workflows, uncomment next line to ignore bower_components 238 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 239 | #bower_components/ 240 | 241 | # RIA/Silverlight projects 242 | Generated_Code/ 243 | 244 | # Backup & report files from converting an old project file 245 | # to a newer Visual Studio version. Backup files are not needed, 246 | # because we have git ;-) 247 | _UpgradeReport_Files/ 248 | Backup*/ 249 | UpgradeLog*.XML 250 | UpgradeLog*.htm 251 | ServiceFabricBackup/ 252 | *.rptproj.bak 253 | 254 | # SQL Server files 255 | *.mdf 256 | *.ldf 257 | *.ndf 258 | 259 | # Business Intelligence projects 260 | *.rdl.data 261 | *.bim.layout 262 | *.bim_*.settings 263 | *.rptproj.rsuser 264 | *- [Bb]ackup.rdl 265 | *- [Bb]ackup ([0-9]).rdl 266 | *- [Bb]ackup ([0-9][0-9]).rdl 267 | 268 | # Microsoft Fakes 269 | FakesAssemblies/ 270 | 271 | # GhostDoc plugin setting file 272 | *.GhostDoc.xml 273 | 274 | # Node.js Tools for Visual Studio 275 | .ntvs_analysis.dat 276 | node_modules/ 277 | 278 | # Visual Studio 6 build log 279 | *.plg 280 | 281 | # Visual Studio 6 workspace options file 282 | *.opt 283 | 284 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 285 | *.vbw 286 | 287 | # Visual Studio LightSwitch build output 288 | **/*.HTMLClient/GeneratedArtifacts 289 | **/*.DesktopClient/GeneratedArtifacts 290 | **/*.DesktopClient/ModelManifest.xml 291 | **/*.Server/GeneratedArtifacts 292 | **/*.Server/ModelManifest.xml 293 | _Pvt_Extensions 294 | 295 | # Paket dependency manager 296 | .paket/paket.exe 297 | paket-files/ 298 | 299 | # FAKE - F# Make 300 | .fake/ 301 | 302 | # CodeRush personal settings 303 | .cr/personal 304 | 305 | # Python Tools for Visual Studio (PTVS) 306 | __pycache__/ 307 | *.pyc 308 | 309 | # Cake - Uncomment if you are using it 310 | # tools/** 311 | # !tools/packages.config 312 | 313 | # Tabs Studio 314 | *.tss 315 | 316 | # Telerik's JustMock configuration file 317 | *.jmconfig 318 | 319 | # BizTalk build output 320 | *.btp.cs 321 | *.btm.cs 322 | *.odx.cs 323 | *.xsd.cs 324 | 325 | # OpenCover UI analysis results 326 | OpenCover/ 327 | 328 | # Azure Stream Analytics local run output 329 | ASALocalRun/ 330 | 331 | # MSBuild Binary and Structured Log 332 | *.binlog 333 | 334 | # NVidia Nsight GPU debugger configuration file 335 | *.nvuser 336 | 337 | # MFractors (Xamarin productivity tool) working folder 338 | .mfractor/ 339 | 340 | # Local History for Visual Studio 341 | .localhistory/ 342 | 343 | # BeatPulse healthcheck temp database 344 | healthchecksdb 345 | 346 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 347 | MigrationBackup/ 348 | 349 | # Ionide (cross platform F# VS Code tools) working folder 350 | .ionide/ 351 | -------------------------------------------------------------------------------- /1-getting-started/code/1-first-app.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Hello World! 8 | 9 | 10 |
11 | {{ message }} 12 |
13 | 14 | 24 | 25 | -------------------------------------------------------------------------------- /1-getting-started/code/2-attribute-bind.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Hello World! 8 | 9 | 10 | 11 |
12 |
13 | {{ message }} 14 |
15 |
16 | 20 |
21 | 22 | 34 | 35 | -------------------------------------------------------------------------------- /1-getting-started/code/3-class-bind.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Hello World! 8 | 9 | 10 | 11 |
12 |
13 | {{ message }} 14 |
15 |
16 | 20 |
21 | 22 | 37 | 38 | -------------------------------------------------------------------------------- /1-getting-started/code/README.md: -------------------------------------------------------------------------------- 1 | # Getting started with Vue.js 2 | 3 | *Vue.js* (also called *Vue*) was created by Evan You and first released in February 2014. His objective for Vue was to create a progressive, lightweight version of JavaScript. 4 | 5 | Vue was designed to allow developers to create a user interface by adding a set of custom HTML attributes that connect software components with data. To accomplish this task, Vue.js interprets the HTML attributes as *directives* that bind input or output parts of the page to a model. The model is represented by standard JavaScript variables. 6 | 7 | You can add the Vue core library to any page and immediately start creating dynamic HTML markup that uses powerful features for data binding and event handling. 8 | 9 | ## Resources 10 | 11 | - [Sample code](./code) 12 | - [Microsoft Learn: Getting started with Vue.js](https://docs.microsoft.com/learn/modules/vue-get-started/) 13 | - [videos](link) 14 | -------------------------------------------------------------------------------- /1-getting-started/code/images/sammy-bath.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/1-getting-started/code/images/sammy-bath.png -------------------------------------------------------------------------------- /1-getting-started/code/index.css: -------------------------------------------------------------------------------- 1 | .important { 2 | font-weight: bold; 3 | font-style: italic; 4 | } 5 | -------------------------------------------------------------------------------- /1-getting-started/code/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Dog pictures 8 | 9 | 10 | 11 |
12 | 13 | {{ message }} 14 | 15 | 19 |
20 | 21 | 22 | 23 | 38 | 39 | -------------------------------------------------------------------------------- /2-logic/README.md: -------------------------------------------------------------------------------- 1 | # Getting started with Vue.js 2 | 3 | When you're creating pages that are based on data, you might need to change the display according to certain values or display multiple items in an array. 4 | 5 | By using Vue.js, you can do these things through a variety of directives. And doing so allows you to use HTML to control the output, which feels natural to many web developers. 6 | 7 | ## Resources 8 | 9 | - [Sample code](./code) 10 | - [Microsoft Learn: Dynamic page displays with Vue.js](https://docs.microsoft.com/learn/modules/vue-dynamic-rendering/) 11 | - [videos](link) 12 | -------------------------------------------------------------------------------- /2-logic/code/1-conditional.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Dog pictures 8 | 9 | 10 | 11 |

Available cruises

12 |
13 | 14 |
15 | {{ cruise.name }} 16 | 20 |
21 |
22 | 23 | 24 | 25 | 39 | 40 | -------------------------------------------------------------------------------- /2-logic/code/2-loops.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Dog pictures 8 | 9 | 10 | 11 |

Available cruises

12 |
13 | 14 | 23 |
24 | 25 | 26 | 27 | 53 | 54 | -------------------------------------------------------------------------------- /2-logic/code/index.css: -------------------------------------------------------------------------------- 1 | body { 2 | font-family: Verdana, Geneva, Tahoma, sans-serif; 3 | } -------------------------------------------------------------------------------- /2-logic/code/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | Relecloud 9 | 10 | 11 | 12 | 13 |

Available cruises

14 |
15 |
16 | {{ cruise.name }} 17 | 21 |
22 |
23 | 24 | 25 | 26 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /3-forms-events/README.md: -------------------------------------------------------------------------------- 1 | # Forms, data and events 2 | 3 | Users typically modify data in a web application by using a form. Because Vue.js is about working with dynamic data, it has a robust mechanism for binding data to forms. You can also manage events, performing different operations when a user selects a button or otherwise interacts with the page. And you can even add values that are computed dynamically, allowing you to minimize the amount of repeated code. 4 | 5 | ## Resources 6 | 7 | - [Sample code](./code) 8 | - [Microsoft Learn: Work with data and events in Vue.js](https://docs.microsoft.com/learn/modules/vue-data-events/) 9 | - [videos](link) 10 | -------------------------------------------------------------------------------- /3-forms-events/code/index-computed.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 17 | 18 |
19 |

Shipping

20 |
21 | 22 |
23 |
24 | 25 |
26 |
27 | 28 |
29 |
30 | 31 |
32 | 33 |

Address sticker

34 |
35 | {{fullAddress}} 36 |
37 | 38 |
39 |

Calculator

40 | + 41 | Sum {{sum}} 42 |
43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /3-forms-events/code/index-computed.html:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-computed.html:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-computed.js: -------------------------------------------------------------------------------- 1 | var app = new Vue({ 2 | el: '#app', 3 | data() { 4 | return { 5 | name: '', 6 | address: '', 7 | city: '', 8 | country: '', 9 | lhs: 0, 10 | rhs: 0 11 | } 12 | }, 13 | computed: { 14 | sum() { 15 | return parseInt(this.lhs) + parseInt(this.rhs); 16 | }, 17 | fullAddress() { 18 | return ` 19 | ${this.name}, ${this.address}, ${this.city.toUpperCase()}, ${this.country.toUpperCase()} 20 | ` 21 | } 22 | } 23 | }) -------------------------------------------------------------------------------- /3-forms-events/code/index-computed.js:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-computed.js:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-event.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 |
13 | 14 |
15 | 16 |
17 |
18 | Coins {{coins}} 19 |
20 |
21 | 22 | 23 | -------------------------------------------------------------------------------- /3-forms-events/code/index-event.html:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-event.html:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-event.js: -------------------------------------------------------------------------------- 1 | // events 2 | // event handler 3 | // event modifier 4 | // shorthand 5 | 6 | var app = new Vue({ 7 | el: '#app', 8 | data() { 9 | return { 10 | coins: 0 11 | } 12 | }, 13 | methods: { 14 | handleClick(e) { 15 | this.coins++; 16 | }, 17 | outerClick(e) { 18 | console.log('outer click'); 19 | } 20 | } 21 | }) -------------------------------------------------------------------------------- /3-forms-events/code/index-event.js:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-event.js:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-form-submit.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 | 22 |
23 |
24 | 25 | 26 |
27 |
28 | 29 | 30 | -------------------------------------------------------------------------------- /3-forms-events/code/index-form-submit.html:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-form-submit.html:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-form-submit.js: -------------------------------------------------------------------------------- 1 | var app = new Vue({ 2 | el: '#app', 3 | methods: { 4 | handleSubmit(e) { 5 | console.log('form submitted') 6 | console.log(e.target.name.value); 7 | console.log(this.name); 8 | } 9 | }, 10 | data() { 11 | return { 12 | name: '' 13 | } 14 | } 15 | }) -------------------------------------------------------------------------------- /3-forms-events/code/index-form-submit.js:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-form-submit.js:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-form-validation.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 | 22 |
23 |
24 | 25 |
26 | 31 | {{name.errorMessage}} 32 |
33 |
34 | 39 | {{postalAddress.errorMessage}} 40 |
41 | 42 |
43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /3-forms-events/code/index-form-validation.html:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-form-validation.html:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-form-validation.js: -------------------------------------------------------------------------------- 1 | var app = new Vue({ 2 | el: '#app', 3 | methods: { 4 | handleSubmit(e) { 5 | console.log('form submitted') 6 | console.log(e.target.name.value); 7 | console.log(this.name); 8 | 9 | }, 10 | handleChange(ev) { 11 | console.log(ev.target.validity); 12 | // logic 13 | this[ev.target.name].valid = ev.target.validity.valid; 14 | if (!ev.target.validity.valid) { 15 | if (ev.target.validity.valueMissing) { 16 | this[ev.target.name].errorMessage = this[ev.target.name].errorMessages.valueMissing; 17 | } else { 18 | this[ev.target.name].errorMessage = 'field not valid'; 19 | } 20 | } else { 21 | this[ev.target.name].errorMessage = ''; 22 | } 23 | } 24 | }, 25 | data() { 26 | return { 27 | name: { 28 | value: '', 29 | valid: true, 30 | errorMessage: '', 31 | errorMessages: { 32 | valueMissing: 'Name is required' 33 | } 34 | }, 35 | postalAddress: { 36 | value: '', 37 | valid: true, 38 | errorMessage: '', 39 | errorMessages: { 40 | valueMissing: 'Postal address is required' 41 | } 42 | } 43 | } 44 | } 45 | }) -------------------------------------------------------------------------------- /3-forms-events/code/index-form-validation.js:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-form-validation.js:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-input.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 21 | 22 |
23 |
24 |
25 | {{title}} 26 | 27 | Value of name {{person.name}} 28 |
29 |
30 | 39 | Selected shipping type {{selectedType}} 40 |
41 |
42 |
43 | 44 | 45 | -------------------------------------------------------------------------------- /3-forms-events/code/index-input.html:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-input.html:Zone.Identifier -------------------------------------------------------------------------------- /3-forms-events/code/index-input.js: -------------------------------------------------------------------------------- 1 | // input 2 | 3 | var app = new Vue({ 4 | el: '#app', 5 | data() { 6 | return { 7 | person : { 8 | name: 'chris' 9 | }, 10 | selectedType: '', 11 | shippingTypes: [{ 12 | name: 'normal' 13 | }, 14 | { 15 | name: 'express' 16 | }] 17 | } 18 | } 19 | }) -------------------------------------------------------------------------------- /3-forms-events/code/index-input.js:Zone.Identifier: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/3-forms-events/code/index-input.js:Zone.Identifier -------------------------------------------------------------------------------- /4-cli-components/README.md: -------------------------------------------------------------------------------- 1 | # Vue CLI and single-file components 2 | 3 | Although it's possible to create an entire Vue.js application in a single JavaScript file, it will become unmanageable in all but the smallest applications. To support breaking your application into smaller units, Vue allows you to create components. Components are reusable building blocks from which you can create your application. 4 | 5 | Components can be created as JavaScript files, or through a single-file component with a .vue extension. Single-file components use a specialized syntax that browsers can't read. This syntax must be converted into the appropriate JavaScript, HTML, and CSS. The process of converting specialized syntax into something a browser can read is called bundling, and it requires extra tooling such as webpack. 6 | 7 | Fortunately, Vue also provides a command-line interface (CLI) that you can use to bootstrap an application. The CLI configures all of the necessary tooling, including a bundler and a development server. 8 | 9 | ## Resources 10 | 11 | - [Sample code](./code) 12 | - [Microsoft Learn: Getting started with Vue CLI and single-file components in Vue.js](https://docs.microsoft.com/learn/modules/vue-cli-components/) 13 | - [videos](link) 14 | -------------------------------------------------------------------------------- /4-cli-components/code/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/4-cli-components/code/.DS_Store -------------------------------------------------------------------------------- /4-cli-components/code/.browserslistrc: -------------------------------------------------------------------------------- 1 | > 1% 2 | last 2 versions 3 | not dead 4 | -------------------------------------------------------------------------------- /4-cli-components/code/README.md: -------------------------------------------------------------------------------- 1 | # my-app 2 | 3 | ## Project setup 4 | ``` 5 | npm install 6 | ``` 7 | 8 | ### Compiles and hot-reloads for development 9 | ``` 10 | npm run serve 11 | ``` 12 | 13 | ### Compiles and minifies for production 14 | ``` 15 | npm run build 16 | ``` 17 | 18 | ### Customize configuration 19 | See [Configuration Reference](https://cli.vuejs.org/config/). 20 | -------------------------------------------------------------------------------- /4-cli-components/code/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "my-app", 3 | "version": "0.1.0", 4 | "private": true, 5 | "scripts": { 6 | "serve": "vue-cli-service serve", 7 | "build": "vue-cli-service build" 8 | }, 9 | "dependencies": { 10 | "vue": "^3.0.0" 11 | }, 12 | "devDependencies": { 13 | "@vue/cli-service": "~4.5.0", 14 | "@vue/compiler-sfc": "^3.0.0" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /4-cli-components/code/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/4-cli-components/code/public/favicon.ico -------------------------------------------------------------------------------- /4-cli-components/code/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | <%= htmlWebpackPlugin.options.title %> 9 | 10 | 11 | 14 |
15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /4-cli-components/code/src/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/microsoft/vue-beginners-videos/3110b6dea9b903915c1eb7e0b028a0bb2ab2d26d/4-cli-components/code/src/assets/logo.png -------------------------------------------------------------------------------- /4-cli-components/code/src/components/BookingForm.vue: -------------------------------------------------------------------------------- 1 | 22 | 23 | 43 | 44 | -------------------------------------------------------------------------------- /4-cli-components/code/src/components/BookingList.vue: -------------------------------------------------------------------------------- 1 | 12 | 13 | 29 | 30 | -------------------------------------------------------------------------------- /4-cli-components/code/src/components/Host.vue: -------------------------------------------------------------------------------- 1 | 25 | 26 | 65 | 66 | -------------------------------------------------------------------------------- /4-cli-components/code/src/main.js: -------------------------------------------------------------------------------- 1 | import { createApp } from 'vue'; 2 | import Host from './components/Host.vue'; 3 | 4 | createApp(Host).mount('#app'); 5 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Microsoft Open Source Code of Conduct 2 | 3 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). 4 | 5 | Resources: 6 | 7 | - [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/) 8 | - [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) 9 | - Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns 10 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) Microsoft Corporation. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Beginner's Series: Vue.js 2 | 3 | This is the supporting repository for the Beginner's Series: Vue.js videos. You will find all the sample code used during the videos, as well as links to additional information and resources. 4 | 5 | ## Vue.js 6 | 7 | Vue.js (also called Vue) was created by Evan You and first released in February 2014. His objective for Vue was to create a progressive, lightweight version of JavaScript. 8 | 9 | Vue was designed to allow developers to create a user interface by adding a set of custom HTML attributes that connect software components with data. To accomplish this task, Vue.js interprets the HTML attributes as directives that bind input or output parts of the page to a model. The model is represented by standard JavaScript variables. 10 | 11 | You can add the Vue core library to any page and immediately start creating dynamic HTML markup that uses powerful features for data binding and event handling, and grow to full modularized applications based around Vue.js using single file components. 12 | 13 | ### Topics covered 14 | 15 | - [Getting started](./1-getting-started) 16 | - [Logic](./2-logic) 17 | - [Forms and events](./3-forms-events) 18 | - [CLI and components](./4-cli-components) 19 | 20 | ### Content authors 21 | 22 | - [Jen Looper](https://twitter.com/jenlooper) 23 | - [Chris Noring](https://twitter.com/chris_noring) 24 | - [Christopher Harrison](https://twitter.com/geektrainer) 25 | 26 | ## Resources 27 | 28 | ### General Vue.js 29 | 30 | If you want to learn more about Vue.js, here's some places to get started: 31 | 32 | - [Videos](link) 33 | - [Microsoft Learn: Taking your first steps with Vue.js](https://docs.microsoft.com/learn/paths/vue-first-steps/) 34 | - [Vue.js](https://v3.vuejs.org/) 35 | 36 | ### Software 37 | 38 | During our videos, we used the following software: 39 | 40 | - [Visual Studio Code](https://code.visualstudio.com) 41 | - Visual Studio Code extensions 42 | - [Live Server](https://marketplace.visualstudio.com/items?itemName=ritwickdey.LiveServer) 43 | - [Vue VSCode Snippets](https://marketplace.visualstudio.com/items?itemName=sdras.vue-vscode-snippets) 44 | - [Node](https://nodejs.org) 45 | - [NPM](https://www.npmjs.com) 46 | - [Vue CLI](https://cli.vuejs.org) 47 | 48 | ## Contributing 49 | 50 | This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com. 51 | 52 | When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA. 53 | 54 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. 55 | 56 | ## Trademarks 57 | 58 | This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow [Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/legal/intellectualproperty/trademarks/usage/general). Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies. 59 | -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | ## Security 4 | 5 | Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/). 6 | 7 | If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below. 8 | 9 | ## Reporting Security Issues 10 | 11 | **Please do not report security vulnerabilities through public GitHub issues.** 12 | 13 | Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report). 14 | 15 | If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/msrc/pgp-key-msrc). 16 | 17 | You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc). 18 | 19 | Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue: 20 | 21 | * Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.) 22 | * Full paths of source file(s) related to the manifestation of the issue 23 | * The location of the affected source code (tag/branch/commit or direct URL) 24 | * Any special configuration required to reproduce the issue 25 | * Step-by-step instructions to reproduce the issue 26 | * Proof-of-concept or exploit code (if possible) 27 | * Impact of the issue, including how an attacker might exploit the issue 28 | 29 | This information will help us triage your report more quickly. 30 | 31 | If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs. 32 | 33 | ## Preferred Languages 34 | 35 | We prefer all communications to be in English. 36 | 37 | ## Policy 38 | 39 | Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/msrc/cvd). 40 | 41 | --------------------------------------------------------------------------------