Skip to content

Commit f5dd231

Browse files
committed
Fix the type definitions for people using TypeScript to write their webpack.config
1 parent 376883c commit f5dd231

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AwsSamPlugin {
2222
private options: AwsSamPluginOptions;
2323
private samConfigs: Array<{ buildRoot: string; entryPointName: string; outFile: string; projectKey: string; samConfig: any }>;
2424

25-
constructor(options: Partial<AwsSamPluginOptions>) {
25+
constructor(options?: Partial<AwsSamPluginOptions>) {
2626
this.entryPoints = {};
2727
this.options = {
2828
projects: { default: "." },
@@ -153,7 +153,7 @@ class AwsSamPlugin {
153153
}
154154

155155
public apply(compiler: any) {
156-
compiler.hooks.afterEmit.tap("SamPlugin", (compilation: any) => {
156+
compiler.hooks.afterEmit.tap("SamPlugin", (_compilation: any) => {
157157
if (this.samConfigs && this.launchConfig) {
158158
for (const samConfig of this.samConfigs) {
159159
fs.writeFileSync(`${samConfig.buildRoot}/template.yaml`, yamlDump(samConfig.samConfig));
@@ -171,4 +171,4 @@ class AwsSamPlugin {
171171
}
172172
}
173173

174-
module.exports = AwsSamPlugin;
174+
export = AwsSamPlugin;

0 commit comments

Comments
 (0)