Skip to content
JavaScript TypeScript CSS HTML
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci fix: npm audit fix Jul 3, 2019
.github feat: probot Mar 19, 2019
__mocks__ fix: monaco mock Jul 3, 2019
bin fix: add CLI Mar 31, 2019
config fix: bump docs-react and cname for build Apr 2, 2019
public fix: html title Feb 15, 2019
scripts fix: bump docs-react and cname for build Apr 2, 2019
src fix: set initial dark theme json view Aug 22, 2019
.editorconfig feat: typescript Mar 20, 2019
.gitignore feat: remove markdown and use material-ui Feb 22, 2019
.releaserc fix: semantic release to npm May 7, 2019
BUILDING.md fix: update BUILDING.md Feb 4, 2019
CNAME feat: initial tests Feb 19, 2019
CONTRIBUTING.md feature: build target file names + release order Feb 4, 2019
CONVENTIONAL_COMMITS.md
LICENSE.md
README.md
RELEASING.md fix: CONTRIBUTING formatting and typo Feb 7, 2019
VERSIONING.md feature: build target file names + release order Feb 4, 2019
jest.config.json feat: typescript Mar 20, 2019
package-lock.json feat: add inspector method plugin + fix theme Aug 19, 2019
package.json
tsconfig.json
tsfmt.json feat: typescript Mar 20, 2019
tslint.json feat: add snackbar notifications to playground Apr 23, 2019

README.md

OpenRPC Playground

A place to play around with OpenRPC.

Dependabot Status

For Non-developers

This is a tool for editing, validating and previewing OpenRPC documents.

What is it?

This is meant to be an all-in-one developer portal for OpenRPC documents. It includes an editor and a live-preview of the documentation.

This helps developers visualize the OpenRPC and iterate very quickly on creating [OpenRPC documents]https://spec.open-rpc.org/#openrpc-document) via the built in editor tooling.

Usage

Navigate to playground.open-rpc.org and start playing around. You can build your own OpenRPC document, validate existing documents quickly, or use the examples.

openrpc-playground-screenshot

Keybinds

  • CTRL + SPACE - auto complete (TAB or ENTER to complete)
  • CTRL + N/CTRL + P - down/up a line (also works as up/down in autocomplete)
  • ALT + SHIFT + F - format document
Chords
  • CMD + K + BACKSPACE - reset to empty schema
  • CMD + K + I - pop up tooltip under cursor
  • CMD + K + V - toggle vim mode
  • CMD + K + R - replace meta schema

Configuration via Query String Parameters

The query string parameters can be used to configure the playground in different ways.

uiSchema

uiSchema is used for UI layer configuration. here is its interface:

image

schemaUrl

schemaUrl - fetch schema by URL and display it as the content of the playground on startup.

schema

schema - JSON String used to display it as the content of the playground on startup.

examples:

  • set splitView to false
    • http://playground.open-rpc.org/?uiSchema[appBar][ui:splitView]=false
  • hide appbar input bar
    • http://playground.open-rpc.org/?uiSchema[appBar][ui:input]=false
  • provide custom name and logo
  • http://playground.open-rpc.org/?uiSchema[appBar][ui:title]=My Site&uiSchema[appBar][ui:logoUrl]=https://github.com/open-rpc/design/raw/master/icons/open-rpc-logo-noText/open-rpc-logo-noText%20(PNG)/128x128.png

Resources and Inspirations

Contributing

This project was bootstrapped with Create React App.

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm test

Launches the test runner in the interactive watch mode.
See the section about running tests for more information.

npm run build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

See the section about deployment for more information.

Learn More

You can learn more in the Create React App documentation.

To learn React, check out the React documentation.

Contributing

How to contribute, build and release are outlined in CONTRIBUTING.md, BUILDING.md and RELEASING.md respectively. Commits in this repository follow the CONVENTIONAL_COMMITS.md specification.

You can’t perform that action at this time.