An AngularJS directive to remove properties from the model when a form control is disabled.
Please see the home page for a full description of purpose and a few examples.
Install using bower:
bower install --save angular-hide-on-disable
Install using npm:
npm install --save angular-hide-on-disable
This package defines an AngularJS module named hide-on-disable
. Since it's registered using angular.module()
method, the script only depends on the existence of the angular
object, and it exports nothing.
The script uses UMD
for compatibility with AMD, CommonJS, ES6 modules, as well as global usage.
Once installed, simply use the following approach corresponding to your preferred transport.
Add a <script>
element after the AngularJS <script>
:
<script src="dist/angular-hide-on-disable.js"></script>
require('angular-hide-on-disable')
Finally, you'll need to add
angular.module('myApp', ['hide-on-disable']);