To set max letters number for textarea, we do achieve that by writing:
<textarea maxLength="50"></textarea>
but, could I do something like below? Is there some way?
import { Component } from '@angular/core';
@Component({
moduleId: module.id,
selector: 'app-create-offer-page',
template: `
<textarea maxLength="textareaLength"></textarea>
`
})
export class CreateOfferPageComponent {
textareaLength: number = 50;
}
I'm asking because that does not work.