Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ngx-autosize-app

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ngx-autosize-app

Directive that automatically adjusts textarea height to fit content

  • 1.8.1-next
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
Maintainers
1
Weekly downloads
 
Created
Source

@techiediaries/ngx-autosize

ngx-autosize is an Angular 10 directive that automatically adjusts textarea height to fit its content.

It adjusts the textarea height automatically to any text input, or changes to the model bound to the textarea.

How to Install?

$ npm install @techiediaries/ngx-autosize

How to Use?

First import the module as follow:

import {AutosizeModule} from '@techiediaries/ngx-autosize';

...

@NgModule({
  imports: [
    AutosizeModule
  ]
})

Use directly inside your HTML templates

<textarea autosize>
    Angular 10 example
</textarea>

Settings

NameDefaultTypeDescription
minRowsintegerSets minimal amount of rows of the textarea
maxRowsintegerSets maximum rows count after which autosizing if turned off and scrollbar appears
onlyGrowfalsebooleanControls if autosize should make the textarea smaller. In other words... should empty lines be trimmed?
useImportantfalsebooleanControls if autosize should include !important in its height css styles. Should only need to be used if the height of the textarea is being overridden elsewhere

Example
You need to implement 'onResized' yourself

## Credits

This library is based
[http://stevepapa.com/angular2-autosize](http://stevepapa.com/angular2-autosize)
and [ngx-autosize](https://www.npmjs.com/package/ngx-autosize)



Keywords

FAQs

Package last updated on 12 Aug 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc