diff --git a/.changeset/shiny-toes-search.md b/.changeset/shiny-toes-search.md new file mode 100644 index 0000000..1d5dd0b --- /dev/null +++ b/.changeset/shiny-toes-search.md @@ -0,0 +1,5 @@ +--- +'axe-reporter-html': patch +--- + +Add missing type declarations. diff --git a/.changeset/tiny-boats-type.md b/.changeset/tiny-boats-type.md new file mode 100644 index 0000000..b64352f --- /dev/null +++ b/.changeset/tiny-boats-type.md @@ -0,0 +1,5 @@ +--- +'axe-reporter-html': patch +--- + +Add missing template to output directory. diff --git a/.npmignore b/.npmignore deleted file mode 100644 index d26b256..0000000 --- a/.npmignore +++ /dev/null @@ -1,2 +0,0 @@ -lib/config/ -test/ diff --git a/package.json b/package.json index a4e1105..ac4ed34 100644 --- a/package.json +++ b/package.json @@ -22,7 +22,8 @@ "types": "lib/index.d.ts", "files": [ "src", - "lib" + "lib", + "template.ejs" ], "scripts": { "lint": "eslint .", diff --git a/src/index.ts b/src/index.ts index 2e7e7bb..f3b3f99 100644 --- a/src/index.ts +++ b/src/index.ts @@ -25,7 +25,7 @@ function prepareResults({ inapplicable, passes, violations }: AxeResults) { } export default async function createHTMLReport(results: AxeResults) { - const templatePath = path.join(__dirname, './template.ejs') + const templatePath = path.join(__dirname, '../template.ejs') const template = await fs.readFile(templatePath, 'utf8') return ejs.render(template, prepareResults(results)) diff --git a/src/template.ejs b/template.ejs similarity index 100% rename from src/template.ejs rename to template.ejs diff --git a/tsconfig.build.json b/tsconfig.build.json index bc66a25..4e20b45 100644 --- a/tsconfig.build.json +++ b/tsconfig.build.json @@ -1,6 +1,8 @@ { "extends": "./tsconfig.json", "compilerOptions": { + "declaration": true, + "declarationMap": true, "noEmit": false }, "include": ["src"]