SourceDirectory context
Always provided by <Output> — useContext(SourceDirectoryContext) is
never undefined inside an <Output> tree. At the root of the tree,
path equals the basePath prop on <Output> (default "./"); nested
<SourceDirectory> components update path relative to their parent.
const SourceDirectoryContext: ComponentContext<SourceDirectoryContext>Accessor
Section titled “Accessor”const myContext = useContext(SourceDirectoryContext);Context interface
Section titled “Context interface”| addContent | (content: SourceDirectoryContext | SourceFileContext | CopyFileContext) => void | |
| contents | (SourceDirectory context interface | SourceFile context interface | CopyFileContext)[] | |
| path | string |