File tree Expand file tree Collapse file tree 1 file changed +22
-1
lines changed
Expand file tree Collapse file tree 1 file changed +22
-1
lines changed Original file line number Diff line number Diff line change 1313
1414` npm i ali-utils --save `
1515
16+ ** IMPORTANT NOTE** : I'm still writing the core libraries, some libs are still unfinished.
17+
1618## Use
1719** a few examples here:**
1820
19- 'Copy' creates a new object from another object, so changing the copy object
21+ ** 'Copy'** creates a new object from another object, so changing the copy object
2022wont change the origin one
2123``` js
2224import {Copy } from ' ali-utils'
@@ -40,6 +42,25 @@ var jane = Copy(john, {
4042})
4143```
4244
45+ ** 'Exclude'** is a function which removes the specified properties.
46+ write the names of the properties you want to exclude inside an array.
47+
48+ ``` js
49+ import {Exclude } from ' ali-utils'
50+
51+ var myData = {
52+ name: ' john' ,
53+ lastName: ' doe' ,
54+ facebook_username: ' john_doe' ,
55+ facebook_password: ' johndoe123'
56+ }
57+
58+ var securedData = Exclude (myData, [' facebook_password' ])
59+
60+ console .log (securedData)
61+ ```
62+
63+
4364## License
4465
4566MIT License
You can’t perform that action at this time.
0 commit comments