react-terminal
Advanced tools
Comparing version 1.0.2 to 1.0.3
{ | ||
"name": "react-terminal", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "React component that renders a terminal", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -44,6 +44,18 @@ <p align="center"> | ||
Also make sure to wrap the main mountpoint around the `TerminalContextProvider`. This retains the state even when the component is unmounted and then mounted back: | ||
``` | ||
import { TerminalContextProvider } from "react-terminal"; | ||
ReactDOM.render( | ||
<TerminalContextProvider> | ||
<MyComponent/> | ||
</TerminalContextProvider>, | ||
rootElement | ||
); | ||
``` | ||
# Props | ||
| name | description | default | | ||
|--|--|--| | ||
| theme | Colour theme of the terminal | "light" | | ||
| theme | Colour theme of the terminal (light/dark) | "light" | | ||
| showControlButtons | Whether to show the control buttons at the top of the terminal | true | | ||
@@ -50,0 +62,0 @@ | prompt | Terminal prompt | >>> |
31934
67