1 | ## TypeScript for pg-minify
|
2 |
|
3 | Complete TypeScript 3.x (`strict` mode) declarations for the module.
|
4 |
|
5 | ### Inclusion
|
6 |
|
7 | Typescript picks up the definitions without any manual configuration.
|
8 |
|
9 | ### Usage
|
10 |
|
11 | ```ts
|
12 | import * as minify from 'pg-minify';
|
13 |
|
14 | const sql = 'SELECT 1; -- comments';
|
15 |
|
16 | minify(sql); //=> SELECT 1;
|
17 | ```
|
18 |
|
19 | And if you are using `"allowSyntheticDefaultImports": true` in your `tsconfig.json`,
|
20 | then you can include it like this:
|
21 |
|
22 | ```ts
|
23 | import minify from 'pg-minify';
|
24 | ```
|
25 |
|
26 | [pg-minify]:https://github.com/vitaly-t/pg-minify
|