How should I write it when I want to embed javascript code in an ionic HTML file?

How to write ionic is as follows

<ion-title>TEST TITLE</ion-title>

I think that I will write like this.

However, what should I do when I want to embed the javascript script tag here?

As it is without body and header tags

<script type = "text/javascript">
    console.log ('test')

I wrote, but there was no response.

I would like to know if there is any way! Thank you!