Skip to content

Commit 4cd7535

Browse files
committed
fix: update types to support ESNext
1 parent fd60cb2 commit 4cd7535

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

index.d.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import { Adapter } from '@sveltejs/kit';
22
import { CustomStaticWebAppConfig } from './types/swa';
33

4-
declare function plugin(opts?: {
4+
type Options = {
55
debug?: boolean;
66
customStaticWebAppConfig?: CustomStaticWebAppConfig;
7-
}): Adapter;
8-
export = plugin;
7+
};
8+
9+
export default function plugin(options?: Options): Adapter;

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function validateCustomConfig(config) {
2424
}
2525
}
2626

27-
/** @type {import('.')} */
27+
/** @type {import('.').default} */
2828
export default function ({ debug = false, customStaticWebAppConfig = {} } = {}) {
2929
return {
3030
name: 'adapter-azure-swa',

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
},
1111
"exports": {
1212
".": {
13+
"types": "./index.d.ts",
1314
"import": "./index.js"
1415
},
1516
"./package.json": "./package.json"

0 commit comments

Comments
 (0)