root / HServer / 00.Server / 00.Program / node_modules / util-deprecate / README.md
이력 | 보기 | 이력해설 | 다운로드 (1.63 KB)
1 |
util-deprecate |
---|---|
2 |
============== |
3 |
### The Node.js `util.deprecate()` function with browser support |
4 |
|
5 |
In Node.js, this module simply re-exports the `util.deprecate()` function. |
6 |
|
7 |
In the web browser (i.e. via browserify), a browser-specific implementation |
8 |
of the `util.deprecate()` function is used. |
9 |
|
10 |
|
11 |
## API |
12 |
|
13 |
A `deprecate()` function is the only thing exposed by this module. |
14 |
|
15 |
``` javascript |
16 |
// setup: |
17 |
exports.foo = deprecate(foo, 'foo() is deprecated, use bar() instead'); |
18 |
|
19 |
|
20 |
// users see: |
21 |
foo(); |
22 |
// foo() is deprecated, use bar() instead |
23 |
foo(); |
24 |
foo(); |
25 |
``` |
26 |
|
27 |
|
28 |
## License |
29 |
|
30 |
(The MIT License) |
31 |
|
32 |
Copyright (c) 2014 Nathan Rajlich <nathan@tootallnate.net> |
33 |
|
34 |
Permission is hereby granted, free of charge, to any person |
35 |
obtaining a copy of this software and associated documentation |
36 |
files (the "Software"), to deal in the Software without |
37 |
restriction, including without limitation the rights to use, |
38 |
copy, modify, merge, publish, distribute, sublicense, and/or sell |
39 |
copies of the Software, and to permit persons to whom the |
40 |
Software is furnished to do so, subject to the following |
41 |
conditions: |
42 |
|
43 |
The above copyright notice and this permission notice shall be |
44 |
included in all copies or substantial portions of the Software. |
45 |
|
46 |
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
47 |
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
48 |
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
49 |
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
50 |
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
51 |
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
52 |
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
53 |
OTHER DEALINGS IN THE SOFTWARE. |