If you are currently working through the CodeHS JavaScript or Advanced JavaScript curriculum, you have likely encountered the exercise 2.3.9: Nested Views. This assignment is a gateway to understanding one of the most powerful concepts in modern user interface (UI) design: layout composition.
// Create a button and add it to the sub-view var button = new Button(100, 100, 100, 50, 'Click me!'); subView.add(button);By completing this exercise, students should be able to: 2.3.9 nested views codehs
Create a rectangle that acts as the main container. Give it a neutral background, like light gray, and a border so you can see its boundaries. Mastering 2
<!-- THE NESTED VIEW STARTS HERE --> <!-- This layout sits inside the main vertical layout --> <LinearLayout android: