Skip to main content

Vector Graphics Spec

Typeobject

VGG Vector Graphics Specification is a JSON-based spec for describing vector graphics.

In the coordinate system defined by VGG, the X-axis increases to the right, and the Y-axis increases upwards. For a given coordinate point:

  • If it is specified as normalized coordinates, it is normalized relative to the width and height in the bounds.
  • Otherwise, the point is non-normalized and in the same coordinate system as the object bounds.
PropertyTypeRequired
versionstringRequired
fileTypeintegerRequired
fileNamestringOptional
framesArray<Frame>Required
referencesArray<ReferencedStyleSymbolMaster>Optional
patternLayerDefArray<PatternLayerDef>Optional

version

Required

Description

Current VGG specs version, conforming to semantic version format like major.minor.patch.

Type

string

Value

constant: the value of this property must be equal to:

"1.0.16"

fileType

Required

Description

The file type of current file.

Type

integer

Value

enum: the value of this property must be equal to one of the following values:

ValueExplanation
0
Unknown
1
Sketch
3
Figma
4
Adobe Illustrator

fileName

Optional

Description

The file name of the input design file, encoding in UTF-8.

Type

string

frames

Required

Description

A list of the frames.

Type

Array<Frame>

references

Optional

Description

A list of the referenced resources.

patternLayerDef

Optional

Description

Illustrator-specific pattern definitions.

Type

Array<PatternLayerDef>