Skip to main content

Interface: CodeViewerProps

Properties

code

Optional code: string

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:27


decorators

Optional decorators: Decorators

Provides a way to draw or style a piece of the content.

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:26


initMode

Optional initMode: SandpackInitMode

This provides a way to control how some components are going to be initialized on the page. The CodeEditor and the Preview components are quite expensive and might overload the memory usage, so this gives a certain control of when to initialize them.

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:35


showLineNumbers

Optional showLineNumbers: boolean

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:22


showTabs

Optional showTabs: boolean

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:21


wrapContent

Optional wrapContent: boolean

Defined in

sandpack-react/src/components/CodeViewer/index.tsx:28