Spaces:
Paused
Paused
Upload index.js
Browse files
index.js
CHANGED
|
@@ -4,7 +4,6 @@ import os from 'os';
|
|
| 4 |
import PDFDocument from 'pdfkit';
|
| 5 |
import fs from 'fs';
|
| 6 |
import axios from 'axios';
|
| 7 |
-
import cheerio from 'cheerio';
|
| 8 |
import { promisify } from 'util';
|
| 9 |
import { createRequire } from 'module';
|
| 10 |
import { fileURLToPath } from 'url';
|
|
@@ -19,7 +18,7 @@ const writeFileAsync = promisify(fs.writeFile);
|
|
| 19 |
const fss = fs.promises;
|
| 20 |
const sizeOf = promisify(require('image-size'));
|
| 21 |
const { exec } = require('child_process');
|
| 22 |
-
|
| 23 |
app.use('/static', express.static(os.tmpdir()));
|
| 24 |
|
| 25 |
function getRandomUserAgent() {
|
|
|
|
| 4 |
import PDFDocument from 'pdfkit';
|
| 5 |
import fs from 'fs';
|
| 6 |
import axios from 'axios';
|
|
|
|
| 7 |
import { promisify } from 'util';
|
| 8 |
import { createRequire } from 'module';
|
| 9 |
import { fileURLToPath } from 'url';
|
|
|
|
| 18 |
const fss = fs.promises;
|
| 19 |
const sizeOf = promisify(require('image-size'));
|
| 20 |
const { exec } = require('child_process');
|
| 21 |
+
const cheerio = require('cheerio');
|
| 22 |
app.use('/static', express.static(os.tmpdir()));
|
| 23 |
|
| 24 |
function getRandomUserAgent() {
|