mirror of
https://github.com/Fdawgs/node-poppler.git
synced 2026-07-02 08:27:45 +08:00
feat: add nodenext compatibility (#470)
This commit is contained in:
+2
-2
@@ -3,5 +3,5 @@
|
||||
# should improve installation performance slightly
|
||||
*
|
||||
!src/index.js
|
||||
!src/index.d.ts
|
||||
!src/lib/**
|
||||
!src/lib/**
|
||||
!types/index.d.ts
|
||||
@@ -33,6 +33,7 @@
|
||||
"unite"
|
||||
],
|
||||
"main": "src/index.js",
|
||||
"types": "types/index.d.ts",
|
||||
"repository": "git+https://github.com/Fdawgs/node-poppler.git",
|
||||
"homepage": "https://github.com/Fdawgs/node-poppler",
|
||||
"bugs": {
|
||||
|
||||
+4
-4
@@ -23,7 +23,8 @@ const errorMessages = {
|
||||
* @param {object} acceptedOptions - Object containing options that a binary accepts.
|
||||
* @param {object} options - Object containing options to pass to binary.
|
||||
* @param {string=} version - Version of binary.
|
||||
* @returns {Array|Error} Array of CLI arguments or Error object if invalid arguments provided.
|
||||
* @returns {Array<string>} Array of CLI arguments.
|
||||
* @throws {Error} If invalid arguments provided.
|
||||
*/
|
||||
function parseOptions(acceptedOptions, options, version) {
|
||||
const args = [];
|
||||
@@ -1519,6 +1520,5 @@ class Poppler {
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
Poppler,
|
||||
};
|
||||
module.exports.Poppler = Poppler;
|
||||
module.exports.default = Poppler;
|
||||
|
||||
+2
-1
@@ -1,9 +1,10 @@
|
||||
{
|
||||
"include": ["src/index.js"],
|
||||
"compilerOptions": {
|
||||
"allowJs": true,
|
||||
"declaration": true,
|
||||
"emitDeclarationOnly": true,
|
||||
"allowJs": true,
|
||||
"outDir": "types",
|
||||
"strict": true
|
||||
}
|
||||
}
|
||||
|
||||
Vendored
+1
@@ -1,3 +1,4 @@
|
||||
export default Poppler;
|
||||
export class Poppler {
|
||||
/**
|
||||
* @param {string=} binPath - Path of poppler-utils binaries.
|
||||
Reference in New Issue
Block a user