Type: Function

How to get useDocumentAspect?


import useDocumentAspect from 'fontoxml-fx/src/useDocumentAspect.js'

Returns a certain aspect of the document with the given id, as set using setDocumentAspect. Will subscribe to changes to the given aspect on the given document and return the current value of the given aspect.

Use documentsManager.setDocumentAspect() to change it (usually not done in a React component).


  1. documentId


    Type: String

    The id of the document to subscribe on

  2. aspectName


    Type: String

    The name of the aspect to subscribe on


Type: any | NULL