Skip to content

Commit 5b8f098

Browse files
committed
Lecture 2 Source
1 parent 8eb035b commit 5b8f098

File tree

4 files changed

+312
-0
lines changed

4 files changed

+312
-0
lines changed

Diff for: .gitignore

+241
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,241 @@
1+
2+
# Created by https://www.gitignore.io/api/vue,node,macos,windows,webstorm,visualstudiocode
3+
# Edit at https://www.gitignore.io/?templates=vue,node,macos,windows,webstorm,visualstudiocode
4+
5+
### macOS ###
6+
# General
7+
.DS_Store
8+
.AppleDouble
9+
.LSOverride
10+
11+
# Icon must end with two \r
12+
Icon
13+
14+
# Thumbnails
15+
._*
16+
17+
# Files that might appear in the root of a volume
18+
.DocumentRevisions-V100
19+
.fseventsd
20+
.Spotlight-V100
21+
.TemporaryItems
22+
.Trashes
23+
.VolumeIcon.icns
24+
.com.apple.timemachine.donotpresent
25+
26+
# Directories potentially created on remote AFP share
27+
.AppleDB
28+
.AppleDesktop
29+
Network Trash Folder
30+
Temporary Items
31+
.apdisk
32+
33+
### Node ###
34+
# Logs
35+
logs
36+
*.log
37+
npm-debug.log*
38+
yarn-debug.log*
39+
yarn-error.log*
40+
41+
# Runtime data
42+
pids
43+
*.pid
44+
*.seed
45+
*.pid.lock
46+
47+
# Directory for instrumented libs generated by jscoverage/JSCover
48+
lib-cov
49+
50+
# Coverage directory used by tools like istanbul
51+
coverage
52+
53+
# nyc test coverage
54+
.nyc_output
55+
56+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
57+
.grunt
58+
59+
# Bower dependency directory (https://bower.io/)
60+
bower_components
61+
62+
# node-waf configuration
63+
.lock-wscript
64+
65+
# Compiled binary addons (https://nodejs.org/api/addons.html)
66+
build/Release
67+
68+
# Dependency directories
69+
node_modules/
70+
jspm_packages/
71+
72+
# TypeScript v1 declaration files
73+
typings/
74+
75+
# Optional npm cache directory
76+
.npm
77+
78+
# Optional eslint cache
79+
.eslintcache
80+
81+
# Optional REPL history
82+
.node_repl_history
83+
84+
# Output of 'npm pack'
85+
*.tgz
86+
87+
# Yarn Integrity file
88+
.yarn-integrity
89+
90+
# dotenv environment variables file
91+
.env
92+
.env.test
93+
94+
# parcel-bundler cache (https://parceljs.org/)
95+
.cache
96+
97+
# next.js build output
98+
.next
99+
100+
# nuxt.js build output
101+
.nuxt
102+
103+
# vuepress build output
104+
.vuepress/dist
105+
106+
# Serverless directories
107+
.serverless/
108+
109+
# FuseBox cache
110+
.fusebox/
111+
112+
# DynamoDB Local files
113+
.dynamodb/
114+
115+
### VisualStudioCode ###
116+
.vscode/*
117+
!.vscode/settings.json
118+
!.vscode/tasks.json
119+
!.vscode/launch.json
120+
!.vscode/extensions.json
121+
122+
### VisualStudioCode Patch ###
123+
# Ignore all local history of files
124+
.history
125+
126+
### Vue ###
127+
# gitignore template for Vue.js projects
128+
#
129+
# Recommended template: Node.gitignore
130+
131+
# TODO: where does this rule come from?
132+
docs/_book
133+
134+
# TODO: where does this rule come from?
135+
test/
136+
137+
### WebStorm ###
138+
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
139+
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
140+
141+
# User-specific stuff
142+
.idea/**/workspace.xml
143+
.idea/**/tasks.xml
144+
.idea/**/usage.statistics.xml
145+
.idea/**/dictionaries
146+
.idea/**/shelf
147+
148+
# Generated files
149+
.idea/**/contentModel.xml
150+
151+
# Sensitive or high-churn files
152+
.idea/**/dataSources/
153+
.idea/**/dataSources.ids
154+
.idea/**/dataSources.local.xml
155+
.idea/**/sqlDataSources.xml
156+
.idea/**/dynamic.xml
157+
.idea/**/uiDesigner.xml
158+
.idea/**/dbnavigator.xml
159+
160+
# Gradle
161+
.idea/**/gradle.xml
162+
.idea/**/libraries
163+
164+
# Gradle and Maven with auto-import
165+
# When using Gradle or Maven with auto-import, you should exclude module files,
166+
# since they will be recreated, and may cause churn. Uncomment if using
167+
# auto-import.
168+
# .idea/modules.xml
169+
# .idea/*.iml
170+
# .idea/modules
171+
172+
# CMake
173+
cmake-build-*/
174+
175+
# Mongo Explorer plugin
176+
.idea/**/mongoSettings.xml
177+
178+
# File-based project format
179+
*.iws
180+
181+
# IntelliJ
182+
out/
183+
184+
# mpeltonen/sbt-idea plugin
185+
.idea_modules/
186+
187+
# JIRA plugin
188+
atlassian-ide-plugin.xml
189+
190+
# Cursive Clojure plugin
191+
.idea/replstate.xml
192+
193+
# Crashlytics plugin (for Android Studio and IntelliJ)
194+
com_crashlytics_export_strings.xml
195+
crashlytics.properties
196+
crashlytics-build.properties
197+
fabric.properties
198+
199+
# Editor-based Rest Client
200+
.idea/httpRequests
201+
202+
# Android studio 3.1+ serialized cache file
203+
.idea/caches/build_file_checksums.ser
204+
205+
### WebStorm Patch ###
206+
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721
207+
208+
# *.iml
209+
# modules.xml
210+
# .idea/misc.xml
211+
# *.ipr
212+
213+
# Sonarlint plugin
214+
.idea/sonarlint
215+
216+
### Windows ###
217+
# Windows thumbnail cache files
218+
Thumbs.db
219+
ehthumbs.db
220+
ehthumbs_vista.db
221+
222+
# Dump file
223+
*.stackdump
224+
225+
# Folder config file
226+
[Dd]esktop.ini
227+
228+
# Recycle Bin used on file shares
229+
$RECYCLE.BIN/
230+
231+
# Windows Installer files
232+
*.cab
233+
*.msi
234+
*.msix
235+
*.msm
236+
*.msp
237+
238+
# Windows shortcuts
239+
*.lnk
240+
241+
# End of https://www.gitignore.io/api/vue,node,macos,windows,webstorm,visualstudiocode

Diff for: lecture-2/hello-world/jquery.html

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6+
<title>jQuery Example</title>
7+
<meta name="viewport" content="width=device-width, initial-scale=1">
8+
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha256-3edrmyuQ0w65f8gfBsqowzjJe2iM6n0nKciPUp8y+7E=" crossorigin="anonymous"></script>
9+
</head>
10+
<body>
11+
<div id="app">
12+
<div></div>
13+
<div></div>
14+
</div>
15+
</body>
16+
<script>
17+
$("#app div:first-child")[0].innerHTML="Hello World";
18+
19+
setTimeout(function () {
20+
$("#app div:nth-child(2)")[0].innerHTML="Changed";
21+
}, 1000);
22+
</script>
23+
</html>

Diff for: lecture-2/hello-world/plain.html

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6+
<title>Plain Javascript Examp,e</title>
7+
<meta name="viewport" content="width=device-width, initial-scale=1">
8+
</head>
9+
<body>
10+
<div id="app"></div>
11+
</body>
12+
<script>
13+
document.getElementById("app").innerHTML="Hello World";
14+
</script>
15+
</html>

Diff for: lecture-2/hello-world/vue.html

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6+
<title>Vue.js Hello World</title>
7+
<meta name="viewport" content="width=device-width, initial-scale=1">
8+
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
9+
</head>
10+
<body>
11+
<div id="app">
12+
<div>
13+
{{ message }}
14+
</div>
15+
<div>
16+
{{ furtherMessage }}
17+
</div>
18+
</div>
19+
</body>
20+
<script>
21+
let vue=new Vue({
22+
el:"#app",
23+
data:{
24+
message:"Hello World",
25+
furtherMessage: null
26+
}
27+
});
28+
29+
setTimeout(function () {
30+
vue.$data.furtherMessage="Changed!";
31+
}, 1000);
32+
</script>
33+
</html>

0 commit comments

Comments
 (0)