mirror of
https://github.com/tabler/tabler-icons.git
synced 2025-08-30 09:10:59 +02:00
headless mode on
This commit is contained in:
@@ -23,7 +23,7 @@ const svgToPng = async (filePath, destination) => {
|
|||||||
filePath = path.join(__dirname, filePath);
|
filePath = path.join(__dirname, filePath);
|
||||||
|
|
||||||
const htmlFilePath = path.join("file:", filePath);
|
const htmlFilePath = path.join("file:", filePath);
|
||||||
const browser = await puppeteer.launch({headless: false});
|
const browser = await puppeteer.launch();
|
||||||
const page = await browser.newPage();
|
const page = await browser.newPage();
|
||||||
|
|
||||||
await page.setViewport({
|
await page.setViewport({
|
||||||
@@ -51,7 +51,7 @@ const createScreenshot = async (filePath) => {
|
|||||||
|
|
||||||
const fileName = filePath.replace('.svg', '');
|
const fileName = filePath.replace('.svg', '');
|
||||||
const htmlFilePath = path.join("file:", filePath);
|
const htmlFilePath = path.join("file:", filePath);
|
||||||
const browser = await puppeteer.launch({headless: false});
|
const browser = await puppeteer.launch();
|
||||||
const page = await browser.newPage();
|
const page = await browser.newPage();
|
||||||
|
|
||||||
await page.setViewport({
|
await page.setViewport({
|
||||||
|
Reference in New Issue
Block a user