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 b582c3d commit 6f61122Copy full SHA for 6f61122
README.md
@@ -172,8 +172,18 @@ HTMLCodeBlockElement.highlight = function (src, options) {
172
// 3. Define
173
customElements.define('code-block', HTMLCodeBlockElement);
174
175
-// 4. Use
+// 4. Make
176
const cbElm = new HTMLCodeBlockElement();
177
+
178
+// 5. Assign
179
+cbElm.language = 'javascript';
180
+cbElm.label = 'your label';
181
+cbElm.value = `const hoge = true;
182
183
+console.log(hoge);`;
184
185
+// 6. Append
186
+document.body.append(cbElm); // Render at the same time
187
```
188
189
##### Syntax
0 commit comments