Export a style to JSON

Shujaat Hussain 1 Reputation point
2024-03-14T08:28:32.1+00:00

Is there a way to export a style to JSON? I see there is importStylesFromJson, but nothing for exporting styles. Alternately, where can I find the full description of the JSON format supported by importStylesFromJson? I need to create a custom style that involves numbering and font formatting.

Use case: customer has provided a Word document containing a style that they want my add-in to inject into active document. But there is no obvious way of converting that style into a programmatic object and then call import on that.

Word
Word
A family of Microsoft word processing software products for creating web, email, and print documents.
689 questions
JavaScript API
JavaScript API
An Office service that supports add-ins to interact with objects in Office client applications.
898 questions
Office Development
Office Development
Office: A suite of Microsoft productivity software that supports common business tasks, including word processing, email, presentations, and data management and analysis.Development: The process of researching, productizing, and refining new or existing technologies.
3,570 questions
0 comments No comments
{count} votes