---
title: "parseGeoJSONFeatureToKeyframes | JavaScript maps SDK"
description: "Documentation for MapTiler SDK"
---

> For AI agents: a documentation index is available at [/llms.txt](https://docs.maptiler.com/llms.txt). Markdown versions of all pages are available by appending .md to any URL.

# Function parseGeoJSONFeatureToKeyframes

-   parseGeoJSONFeatureToKeyframes(  
        feature: [KeyframeableGeoJSONFeature](https://docs.maptiler.com/sdk-js/api-reference/types/KeyframeableGeoJSONFeature/),  
        options?: [ParseGeoJSONToKeyframesOptions](https://docs.maptiler.com/sdk-js/api-reference/interfaces/ParseGeoJSONToKeyframesOptions/),  
    ): [Keyframe](https://docs.maptiler.com/sdk-js/api-reference/types/Keyframe/)\[\][](#parsegeojsonfeaturetokeyframes)
    
    Converts a GeoJSON feature into an array of animation keyframes.
    
    Parses a GeoJSON feature with reserved properties to create animation keyframes. It extracts coordinates from the geometry and uses properties prefixed with '@' as animation control parameters (easing functions, delta values). Non-reserved properties are preserved and passed to the keyframe objects as props that will be interpolated
    
    #### Parameters
    
    -   feature: [KeyframeableGeoJSONFeature](https://docs.maptiler.com/sdk-js/api-reference/types/KeyframeableGeoJSONFeature/)
        
        The GeoJSON feature to convert to keyframes
        
    -   options: [ParseGeoJSONToKeyframesOptions](https://docs.maptiler.com/sdk-js/api-reference/interfaces/ParseGeoJSONToKeyframesOptions/) = {}
        
        Configuration options
        
    
    #### Returns [Keyframe](https://docs.maptiler.com/sdk-js/api-reference/types/Keyframe/)\[\]
    
    Array of keyframe objects that can be used for animation
    
    #### Throws[](#throws)
    
    When no geometry is found in the feature
    
    #### Throws[](#throws-1)
    
    When the geometry type is not supported
