Config File
The docsync.config.json file is the heart of your visual documentation. It defines global settings, scenarios, and variant configurations.
File Location
The config file should be in your project root:
my-project/
├── docsync.config.json
├── package.json
└── ...Basic Structure
{
"baseUrl": "http://localhost:3000",
"assetDir": ".poliage/output",
"concurrency": 2,
"timeout": 45000,
"headless": true,
"viewport": {
"width": 1280,
"height": 720
},
"scenarios": [],
"variants": {}
}Global Settings
Viewport Configuration
{
"viewport": {
"width": 1280,
"height": 720,
"deviceScaleFactor": 2
}
}Storage Configuration
Configure where assets are uploaded:
{
"storage": {
"type": "poliage"
}
}See Publishing for all storage options.
Output Format Configuration
Configure the default output format for captures:
{
"output": {
"primaryFormat": "gif",
"staticFormat": "png",
"gif": {
"loop": true,
"fps": 15,
"quality": "high",
"maxDuration": 10000
}
}
}Example Configuration
{
"baseUrl": "http://localhost:3000",
"assetDir": ".poliage/output",
"concurrency": 3,
"timeout": 60000,
"headless": true,
"viewport": {
"width": 1440,
"height": 900
},
"storage": {
"type": "poliage"
},
"diffing": {
"enabled": true,
"threshold": 0.1
},
"scenarios": [
{
"name": "homepage",
"steps": [
{ "action": "goto", "url": "/" },
{ "action": "capture", "key": "hero-section" }
]
}
]
}