0
Fork 0
mirror of https://github.com/penpot/penpot-export.git synced 2025-02-02 04:08:57 -05:00
penpot-export/packages/demo/penpot-export.config.js

62 lines
1.8 KiB
JavaScript
Raw Normal View History

// @ts-check
2023-08-21 08:36:47 +02:00
require('dotenv').config()
if (typeof process.env.PENPOT_ACCESS_TOKEN !== 'string') {
throw new Error('Missing PENPOT_ACCESS_TOKEN environment variable')
}
2023-08-21 08:36:47 +02:00
/**
* @type {import('@penpot-export/core').UserConfig}
2023-08-21 08:36:47 +02:00
*/
const config = {
instance: process.env.PENPOT_BASE_URL || undefined,
2023-08-21 08:36:47 +02:00
accessToken: process.env.PENPOT_ACCESS_TOKEN,
2023-08-30 15:17:57 +02:00
files: [
{
2023-08-30 15:17:57 +02:00
fileId: 'abea3ef6-4c19-808a-8003-01370d9cb586',
pages: [
{
pageId: '71b1702b-2eb1-81d6-8002-f82a5f182088',
2023-08-31 20:28:14 +02:00
output: 'src/styles/ui.css', // 👈 Path where your CSS file should be generated.
2023-08-30 15:17:57 +02:00
},
2023-09-05 14:43:33 +02:00
{
pageId: '71b1702b-2eb1-81d6-8002-f82a5f182088',
output: 'src/styles/ui.json', // 👈 Path where your JSON file should be generated.
format: 'json',
},
2023-08-30 15:17:57 +02:00
],
2023-08-22 18:19:28 +02:00
},
2023-08-21 08:36:47 +02:00
{
2023-08-30 15:17:57 +02:00
fileId: '4a499800-872e-80e1-8002-fc0b585dc061',
colors: [
{
2023-08-31 20:28:14 +02:00
output: 'src/styles/colors.css', // 👈 Path where your CSS file should be generated.
2023-08-30 15:17:57 +02:00
},
2023-09-07 15:15:30 +02:00
{
output: 'src/styles/colors.scss', // 👈 Path where your SCSS file should be generated.
format: 'scss',
},
2023-09-05 14:43:33 +02:00
{
output: 'src/styles/colors.json', // 👈 Path where your JSON file should be generated.
format: 'json',
},
2023-08-30 15:17:57 +02:00
],
typographies: [
{
2023-08-31 20:28:14 +02:00
output: 'src/styles/typographies.css', // 👈 Path where your CSS file should be generated.
2023-08-30 15:17:57 +02:00
},
2023-09-07 15:15:30 +02:00
{
output: 'src/styles/typographies.scss', // 👈 Path where your SCSS file should be generated.
format: 'scss',
},
2023-09-05 14:43:33 +02:00
{
output: 'src/styles/typographies.json', // 👈 Path where your JSON file should be generated.
format: 'json',
},
2023-08-30 15:17:57 +02:00
],
2023-08-21 08:36:47 +02:00
},
],
}
module.exports = config