Skip to content

Commit 4593470

Browse files
committed
空行の規則の変更
1 parent d078d6e commit 4593470

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

docs/3-web-servers/06-fetch-api/index.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,11 @@ import express from "express";
2323

2424
const app = express();
2525
app.use(express.static("./public"));
26+
2627
app.get("/weather", (request, response) => {
2728
response.send("晴れ");
2829
});
30+
2931
app.listen(3000);
3032
```
3133

@@ -44,6 +46,7 @@ async function fetchWeather() {
4446
const weather = await response.text();
4547
document.getElementById("weather").textContent = weather;
4648
}
49+
4750
fetchWeather();
4851
```
4952

@@ -115,12 +118,14 @@ import express from "express";
115118

116119
const app = express();
117120
app.use(express.static("./public"));
121+
118122
app.get("/weather", (request, response) => {
119123
response.json({
120124
condition: "晴れ",
121125
temperature: 25,
122126
});
123127
});
128+
124129
app.listen(3000);
125130
```
126131

@@ -138,6 +143,7 @@ async function fetchWeather() {
138143
document.getElementById("condition").textContent = weather.condition;
139144
document.getElementById("temperature").textContent = weather.temperature;
140145
}
146+
141147
fetchWeather();
142148
```
143149

0 commit comments

Comments
 (0)