When a single language is not sufficient to run the code, we use multiple <panel>
tags inside our <codeblock>
.
For example, if we need HTML, CSS and JS to run our code, then we need to use panels for HTML, CSS and JS inside the codeblock
.
Its attributes include:
1. <panel language="css" >
Similar to codeblock
, the language
attribute in panel
is used to specify the choice of programming language.
language attribute of panel tag currently supports css, html and javascript values for CSS, HTML and JavaScript codes.
2. <panel hidden="true">
The hidden
attribute is used to hide the code panel.
For example, we might have added some CSS which is for styling the result. It might not specifically relate to the learnings in the lesson. In this case, we can hide the CSS panel
using the hidden
attribute.
3. <panel foldLines="1-3, 4-9">
Similar to codeblock
, the foldLines
attribute is used to fold the lines of code on default load of the editor.