astralarya / React Console
Licence: gpl-3.0
Simple react console emulator
Stars: ✭ 64
Programming Languages
typescript
32286 projects
Projects that are alternatives of or similar to React Console
React Notifications Component
Delightful and highly customisable React Component to notify your users
Stars: ✭ 978 (+1428.13%)
Mutual labels: react-component
React Contenteditable
React component for a div with editable contents
Stars: ✭ 1,057 (+1551.56%)
Mutual labels: react-component
React Filtered Multiselect
Filtered multi-select React component
Stars: ✭ 61 (-4.69%)
Mutual labels: react-component
Reimgix
🌇 Get all the benefits of Imgix using React. Supports LQIP.
Stars: ✭ 39 (-39.06%)
Mutual labels: react-component
React Echarts V3
React.js(v16.x+) component wrap for ECharts.js(v3.x+)
Stars: ✭ 48 (-25%)
Mutual labels: react-component
React Stonecutter
Animated grid layout component for React
Stars: ✭ 1,089 (+1601.56%)
Mutual labels: react-component
React Animated Weather
Animated weather component for React inspired by Skycons http://darkskyapp.github.io/skycons/ ☀️
Stars: ✭ 34 (-46.87%)
Mutual labels: react-component
Ishell
Library for creating interactive cli applications.
Stars: ✭ 1,127 (+1660.94%)
Mutual labels: readline
React No Content
A SVG react component to display when there's no content.
Stars: ✭ 59 (-7.81%)
Mutual labels: react-component
React Sane Contenteditable
React component with sane defaults to make any element contentEditable
Stars: ✭ 45 (-29.69%)
Mutual labels: react-component
React Topbar Progress Indicator
`topbar` progress indicator as a React component
Stars: ✭ 58 (-9.37%)
Mutual labels: react-component
Spicy Datatable
React.js datatables without jQuery. Smart react datatable that includes search, pagination and localization.
Stars: ✭ 36 (-43.75%)
Mutual labels: react-component
React Xmasonry
Simple, minimalistic and featured native masonry layout for React JS.
Stars: ✭ 62 (-3.12%)
Mutual labels: react-component
React Markdown Preview
React component preview markdown text in web browser. The minimal amount of CSS to replicate the GitHub Markdown style.
Stars: ✭ 34 (-46.87%)
Mutual labels: react-component
Crossline
A small, self-contained, zero-config, MIT licensed, cross-platform, readline and libedit replacement.
Stars: ✭ 53 (-17.19%)
Mutual labels: readline
React Bps
🔱 Create breakpoints to your component props
Stars: ✭ 64 (+0%)
Mutual labels: react-component
Webterminal
ssh rdp vnc telnet sftp bastion/jump web putty xshell terminal jumpserver audit realtime monitor rz/sz 堡垒机 云桌面 linux devops sftp websocket file management rz/sz otp 自动化运维 审计 录像 文件管理 sftp上传 实时监控 录像回放 网页版rz/sz上传下载/动态口令 django
Stars: ✭ 1,124 (+1656.25%)
Mutual labels: terminal-emulators
React Router Form
<Form> is to <form> as <Link> is to <a>
Stars: ✭ 58 (-9.37%)
Mutual labels: react-component
react-console
Simple React.js console emulator.
Example
Simple prompt that echoes back input:
let EchoConsole = React.createClass({
echo: function(text) {
this.refs.console.log(text);
this.refs.console.return();
},
render: function() {
return <Console ref="console"
handler={this.echo}
autofocus={true}
/>;
}
});
See the example project used in the live demo.
Installation
npm install --save-dev react-console-component
Features
- Readline emulation
- Mobile friendly
- Input Method Editor (IME) support
Props
Properties you can pass to the console element
Prop | Type | Description |
---|---|---|
autofocus? | bool | Autofocus the console on component mount. |
cancel? | ()=>any | Function that should stop execution of the current command and call this.return() . |
complete? | (words: string[], cursor: number, prompt: string)=>string[] | Return a list of possible completions given a list of (words ), index of the word containing the cursor (cursor ) , and the full prompt text (prompt ). |
continue? | (prompt: string)=>bool | Return a boolean indicating whether to continue asking for user input on a newline given the current prompt text (prompt ). |
handler | (command: string)=>any | Handle a command (command ), logging data with this.log() or this.logX() , and calling this.return() when finished. |
promptLabel? | string | ()=>string | String or function that generates a string displayed to prompt user for input. |
welcomeMessage? | string | Initial message displayed after mount. |
Public members
Member | Type | Description |
---|---|---|
log | (...messages: any)=>void | Log messages to the console. If string, print the value, otherwise, print the JSON value of the message. |
logX | (type: string, ...messages: any)=>void | Log messages of a particular type to the console. The messages will be given the class react-console-message-{type} . |
return | ()=>void | Signal the current command has finished and a new prompt should be displayed. |
Awknoledgements
React-console is inspired by chrisdone/jquery-console.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].