render() {
          return(
            <div className="app__container">
              <SidebarComponent 
                selectedNoteIndex={this.state.selectedNoteIndex}
                notes={this.state.notes}
                classes={this.state.classes}
                deleteNote={this.deleteNote}
                selectNote={this.selectNote}
                newNote={this.newNote}>
              </SidebarComponent>
              {
                this.state.selectedNote ? // is the note is not selected render null else render the note
                <EditorComponent 
                selectedNote={this.state.selectedNote}
                selectedNoteIndex={this.state.selectedNoteIndex}
                notes={this.state.notes}
                noteUpdate={this.noteUpdate}>
                </EditorComponent> : null
              }
            </div>
          );
        }

      Javascript language logo
      your recipe card header background
      renderContainer

      Components

      This code renders a <div> for the main content of the App and a SidebarComponent for the user to select a Note from the currently selected NoteIndex. EachNote has an associated set of Notes, a NoteUpdate function to update the Notes and an EditorComponent to edit the Note.

      Shortcut: render.Contain

      0 Comments

        Add Comment

        Log in to add a comment

        Codiga - All rights reserved 2022.