textContent Material Designer Angular JS

3

I'm using Angular Material Dialog and everything is fine, but when I put textContent it returns the following error:

CONSOLE ERROR

 $mdDialog.confirm(...).title(...).textContent is not a function

JS

var confirm = $mdDialog.confirm()
              .title('Você tem certeza que deseja excluir esta categoria?')
              .textContent('Esta ação é irreversível')
              .ariaLabel('Excluir')
              .targetEvent(ev)
              .ok('Sim tenho certeza!')
              .cancel('Não excluir');

        $mdDialog.show(confirm).then(function() {
            // ok
        }, function() {
          // cancelado
        });

Why is this textContent not accepted? The example is the same as the Angular JS Material.

    
asked by anonymous 04.12.2015 / 14:17

1 answer

5

The version you are using is probably earlier than 1.0.0, In previous versions instead of textContent the function was just called content .

You can follow the examples of the official website depending on the version you are using, just change where it shows the image below.

    
04.12.2015 / 14:30