Merge pull request #13588 from Snuffleupagus/viewer-component-types
Add a (basic) TypeScript definitions for the viewer components (issue 13267)
This commit is contained in:
commit
94ca66f528
1
external/dist/legacy/web/pdf_viewer.d.ts
vendored
Normal file
1
external/dist/legacy/web/pdf_viewer.d.ts
vendored
Normal file
@ -0,0 +1 @@
|
||||
export * from "pdfjs-dist/types/web/pdf_viewer.component.d.ts";
|
2
external/dist/lib/README.md
vendored
2
external/dist/lib/README.md
vendored
@ -3,5 +3,5 @@ pre-built library as found in e.g. the `/build`, `/web`, and `/image_decoders`
|
||||
folders in the root of this repository.
|
||||
|
||||
Please note that the "lib" build target exists mostly to enable unit-testing in
|
||||
Node.js/Travis, and that you'll need to handle e.g. any necessary polyfills
|
||||
Node.js/GitHub, and that you'll need to handle e.g. any necessary polyfills
|
||||
and/or Node.js dependencies yourself if using the files in this folder.
|
||||
|
1
external/dist/web/pdf_viewer.d.ts
vendored
Normal file
1
external/dist/web/pdf_viewer.d.ts
vendored
Normal file
@ -0,0 +1 @@
|
||||
export * from "pdfjs-dist/types/web/pdf_viewer.component.d.ts";
|
@ -1382,7 +1382,10 @@ gulp.task("types", function (done) {
|
||||
"emitDeclarationOnly",
|
||||
"moduleResolution node",
|
||||
].join(" --");
|
||||
exec(`"node_modules/.bin/tsc" --${args} src/pdf.js`, done);
|
||||
exec(
|
||||
`"node_modules/.bin/tsc" --${args} src/pdf.js web/pdf_viewer.component.js`,
|
||||
done
|
||||
);
|
||||
});
|
||||
|
||||
function buildLibHelper(bundleDefines, inputStream, outputDir) {
|
||||
@ -1993,7 +1996,7 @@ function packageBowerJson() {
|
||||
name: DIST_NAME,
|
||||
version: VERSION,
|
||||
main: "build/pdf.js",
|
||||
types: "types/pdf.d.ts",
|
||||
types: "types/src/pdf.d.ts",
|
||||
description: DIST_DESCRIPTION,
|
||||
keywords: DIST_KEYWORDS,
|
||||
homepage: DIST_HOMEPAGE,
|
||||
|
Loading…
Reference in New Issue
Block a user