I'm using a Bootstrap Form Input to allow the user to pass in some text. How do I go about saving that text and using it as a parameter in a function?
Here's my HTML:
<!--Directory Input Form-->
<div class="row">
<div class="input-group">
<span class="input-group-addon" id="basic-addon3">Directory</span>
<input type="text" class="form-control" id="basic-url" aria-describedby="basic-addon3">
</div>
</div>
<!--Convert Button-->
<div class="panel-body">
<button type="button" class="btn btn-primary" (click)="convert(inputString);">Convert</button>
</div>
As you can see, I have a call to a method called convert(inputString) that takes in a string parameter (convert(string s) is implemented in my TypeScript folder). I placed 'inputString' inside the method to better illustrate my question even though I know I don't have an id for inputString anywhere else. Is that the proper way to go about this - creating an id with the name inputString and linking it to the text the user inputs? If so, how do I go about doing that?