Skip to content

Commit bd8136d

Browse files
committed
Update package.json, tsconfig.json, and tsup.config.ts for improved build setup
1 parent 0dfe2cb commit bd8136d

File tree

5 files changed

+476
-662
lines changed

5 files changed

+476
-662
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -172,16 +172,16 @@ If you prefer not to install the package and want to include the ECMAScript modu
172172
project, you can use the following script tag:
173173

174174
- CDN (
175-
jsDelivr): [`https://cdn.jsdelivr.net/npm/[email protected].10/dist/index.mjs`](https://cdn.jsdelivr.net/npm/[email protected]/dist/index.mjs)
175+
jsDelivr): [`https://cdn.jsdelivr.net/npm/[email protected].11/dist/index.mjs`](https://cdn.jsdelivr.net/npm/[email protected]/dist/index.mjs)
176176

177-
- NPM: [`https://unpkg.com/[email protected].10/dist/index.mjs`](https://unpkg.com/[email protected]/dist/index.mjs)
177+
- NPM: [`https://unpkg.com/[email protected].11/dist/index.mjs`](https://unpkg.com/[email protected]/dist/index.mjs)
178178

179179
Import Statement:
180180

181181
```html
182182

183183
<script type="module">
184-
import usePostalPH from 'https://unpkg.com/[email protected].10/dist/index.mjs';
184+
import usePostalPH from 'https://unpkg.com/[email protected].11/dist/index.mjs';
185185
186186
const {
187187
fetchDataLists,

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "use-postal-ph",
3-
"version": "1.1.10",
3+
"version": "1.1.11",
44
"description": "This utility library is specifically designed for the Philippines, providing comprehensive information on postal codes,\nmunicipalities, locations, and regions. Moreover, searching within the library is case insensitive.",
55
"main": "./dist/index.js",
66
"module": "./dist/index.mjs",

tsconfig.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,23 @@
55
"esModuleInterop": true,
66
"allowSyntheticDefaultImports": true,
77
"strictNullChecks": true,
8-
"module": "CommonJS",
8+
"module": "ESNext",
99
"moduleResolution": "Node",
1010
"isolatedModules": true,
1111
"strictBindCallApply": true,
1212
"noUnusedLocals": true,
1313
"noUnusedParameters": true,
14+
"skipLibCheck": true,
1415
"outDir": "./dist",
1516
"target": "ES5",
17+
"removeComments": true,
18+
"declarationMap": true,
1619
"lib": [
17-
"ES2016",
20+
"ES5",
1821
"DOM"
1922
]
2023
},
2124
"include": [
22-
"src",
2325
"src/**/*.ts"
2426
],
2527
"exclude": [

tsup.config.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,14 @@ export default defineConfig({
1212
target: 'es5',
1313
outDir: './dist',
1414
terserOptions: {
15-
mangle: true,
16-
compress: true,
15+
mangle: {
16+
toplevel: true,
17+
},
18+
compress: {
19+
passes: 2,
20+
drop_console: true,
21+
drop_debugger: true
22+
},
1723
ecma: 5,
1824
},
1925
});

0 commit comments

Comments
 (0)