Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
第五回後期ネットワークチーム講座
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
北海道科学大学 電子計算機研究部
November 21, 2016
Education
87
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
第五回後期ネットワークチーム講座
北海道科学大学 電子計算機研究部
November 21, 2016
More Decks by 北海道科学大学 電子計算機研究部
See All by 北海道科学大学 電子計算機研究部
第12回Network講座2019
densan
1
69
第11回Network講座2019
densan
0
86
第10回Network講座2019
densan
0
64
第09回Network講座2019
densan
1
180
第08回Network講座2019
densan
0
59
第07回Network講座2019
densan
0
61
第06回Network講座2019
densan
0
84
第05回Network講座2019
densan
0
61
第04回Network講座2019
densan
0
130
Other Decks in Education
See All in Education
[2026後期火5] 論理学(京都大学文学部 後期 第2回)「量化子の導入」
yatabe
0
180
観察、仮説、実行、検証、計画、提案を一年で3000回トレーニングする方法/3000 Thinking Loops in 365 Days
moriyuya
5
1.5k
One Year of Learning English with AI @エンジニア英語キャリア Meetup #3
kekekenta
0
300
中小規模私大の教学IRを支えるデータマネジメント ― データ基盤構築の取り組みと実務の現在地 ―
terazawa
0
230
Requirements Analysis and Prototyping - Lecture 3 - Human-Computer Interaction (1023841ANR)
signer
PRO
0
1.8k
Réunion des directrices et directeurs des écoles de la circonscription de Jonzac - 31 août 2026
fmarot
0
160
DecisionesEjecutivasCrisis
mariooc
0
430
AIでアウトプットできる時代だからこそ、自分の言葉で考えることの大切さ / What's Left to Think, When AI Can Write?
masakiokuda
1
370
CSS3 and Responsive Web Design - Lecture 5 - Web Technologies (1019888BNR)
signer
PRO
1
3.5k
学習者データを「見る」:外国語教師のためのデータの入力、分析、解釈方法
uranoken
0
440
2026年度秋学期 統計学 第3回 クロス集計と感度・特異度,データの可視化 (2026. 10. 13)
akiraasano
PRO
0
260
2026年度秋学期 統計学 第2回 統計資料の収集と読み方 (2026. 10. 6)
akiraasano
PRO
0
270
Featured
See All Featured
Abbi's Birthday
coloredviolet
4
10k
ラッコキーワード サービス紹介資料
rakko
1
5.4M
The Curse of the Amulet
leimatthew05
3
16k
Google's AI Overviews - The New Search
badams
0
1.6k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
310
jQuery: Nuts, Bolts and Bling
dougneiner
66
8.6k
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
270
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.7k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
260
Balancing Empowerment & Direction
lara
6
1.3k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.6k
Transcript
ネットワークチーム 後期第五回講座資料 アプリケーション作成
目次 • アプリケーション作成 • 用語解説
準備 1. 作業用フォルダでコマンドプロンプトを開く 2. npm init を実行 (その後は特にこだわりがなければ全てEnterでよい)
package.json • npm init を実行すると package.json が作られる • JSONは、JavaScript のオブジェクトと同様の記法で書か
れたテキストファイル プログラムにデータを渡す際などに使用される
package.json の中身 → 入っていないモジュールがある 場合、以下を実行 npm install --save モジュール名
package.json • 内容を見ると、現在インストールしているモジュールが “dependencies :” に書き込まれている 新たにモジュールを追加する場合、インストール時に ”--save” オプションを使用する •
npm update で一括アップデート、npm start で実行 etc…
Pug(旧Jade)の記法 ①基本的にタグ名のみ記述 (<>いらず、閉じタグもなし) ② インデントを用いて階層構造を表現する ③タグ名の後に( )を付けて属性の指定ができる
Pug(Jade)の記法 ④ 簡単な制御構文(While, If など)や変数、JSコードが利用で きる JSのコードは先頭に” – “(ハイフン)を付けて記述する ⑤
変数を呼び出す場合、 #{変数名} または =変数名 と記述 ⑥ コマンドを用いることでテンプレートの継承ができる
• app.js を次の2ページの通り記述 一つのjsファイルに続けて書く (全28行)
None
None
• 次に、app.js があるフォルダ内に 「views」 というフォルダを作成 (ついでに 「public」 というフォルダも作成)
Pugファイル作成 • views/index.pug (全4行)
Pugファイル作成 • views/layout.pug (全10行)
CSS作成 • public/css/style.css
レンダリング • テンプレートエンジンからHTMLを生成すること • render関数でこれが行われている
レンダリング • render関数から渡された値はpugファイルで指定された場所に 代入される
ルーティング • リクエストされたURLに対して呼び出すアクションを変更する仕組 Localhost:3000/ にアクセスした場合 ↓ Localhost:3000/hello/ にアクセスした場合 ↓