We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7e63898 commit 9e9c852Copy full SHA for 9e9c852
docs/1-trial-session/13-dom/index.md
@@ -55,4 +55,17 @@ element.style.backgroundColor = "red";
55
56
[CSS の節](../12-css/index.md)の課題を、<Term type="styleAttribute">style 属性</Term>を使用せずに JavaScript のみで実現してみましょう。
57
58
+<Answer type="JSを用いたCSSスタイリング">
59
+
60
+```javascript
61
+const element = document.getElementById("foo");
62
+element.style.border = "1px solid #aaa";
63
+element.style.borderRadius = "10px";
64
+element.style.margin = "30px";
65
+element.style.padding = "30px";
66
+element.style.boxShadow = "0px 0px 2px 1px #aaa";
67
+```
68
69
<ViewSource url={import.meta.url} path="_samples/css" />
70
71
+</Answer>
0 commit comments