Creating a viewer or a modeler

Hello. I am new to the forum.

I started studying bpmn.io and i am stuck in a newbie question.

Comparing viewer and modeler basic examples i do not get why in one case a viewer is created and a modeler in the other:

// code from viewer example:

      // viewer instance
      var bpmnViewer = new BpmnJS({
        container: '#canvas'
      });

// code from modeler example:

      // modeler instance
      var bpmnModeler = new BpmnJS({
        container: '#canvas',
        keyboard: {
          bindTo: window
        }
      });

thery are both new BpmnJS objects, where do i tell to create a viewer explcitly?

Thanks.

Have you checked out the walktrough for the toolkit: https://bpmn.io/toolkit/bpmn-js/walkthrough/