/editor

An interactive scientific editor built with ProseMirror, React and Redux - by Curvenote.

Primary LanguageTypeScriptMIT LicenseMIT

@curvenote/editor

@curvenote/editor on npm MIT License CI demo

An interactive scientific editor built with ProseMirror, React and Redux - by Curvenote.

@curvenote/editor in curvenote.com

Why

We think that creating beautiful reactive documents and explorable explanations should be easy. Writing technical documents is hard enough already, and choosing to make that writing interactive is beyond the reach or time-commitment of most communicators.

We aim to lower the barriers to writing computational narratives. Today, narrative is often moved out of computational notebooks into static document creation tools (Microsoft Word, Google Docs, LaTeX, Slides/PPT).

We think this is for two reasons:

  1. The need for more expressive components, formatting or referencing.
    • CommonMark markdown does not support, for example, citations, cross-references, and even simple formatting like callouts (see various alternatives below).
  2. To enable collaborators and reviewers who don't use these tools (e.g. when writing and reviewing papers & reports, slide decks, etc.)
    • Writing often requires collaborators that may not be comfortable with some combination of the tools required for computational narratives (e.g. git, md, notebooks, javascript, etc.).

Goals

@curvenote/editor aims to bridge the gap between expressiveness and writing accessibility by developing a rich, WYSIWYG, collaborative editor with a focus on interactivity that integrates with LaTeX, various flavours of Markdown, and the Jupyter and Sphinx ecosystems.

Overlap with Curvenote

@curvenote/editor is the editor that is used in Curvenote, a scientific writing platform that connects to Jupyter.

Alternatives

There are many Markdown syntax variants and extensions (e.g. RMarkdown, MyST Markdown, idyll-lang, MDX) that add flavours (usually) on top of CommonMark to allow for more complex documents and various degrees of interactivity. These syntaxes or development environments are often beyond the reach of many contributors and collaborative editing and review is often difficult.

Interactivity

We think the best explanations are explorable and promote active reading, and would love to see this style of writing more widely adopted in scientific teaching, writing and education. To us, that means deep integrations with the Jupyter ecosystem and providing ways to support traditional export as well.

Scope of Repository

A WYSIWYG editor for technical content and documents (papers, reports, documentation, etc.), and support computational into the narrative (c.f. explorable explanations).

Specifically:

  • A stand alone scientific editor that can be integrated into other applications, React will be supported first-class.
  • Integration points for collaboration, citations, and interactivity/reactivity.
  • Prosemirror plugins for technical writing, comments, etc.

Monorepo

The editor package is a monorepo that is built with turborepo. Included in this repository are:

Related packages

A collaborative, rich text editor for interactive technical & scientific content., implementing the MyST Markdown, and integrating with JupyterLab, JupyterBook and Sphinx. The project will enable a larger audience to create publication-quality, standards-friendly documents through Jupyter, without having to learn a new syntax.

Roadmap

We use this editor at Curvenote where we have worked on it for the last few years. We will continue to spin out useful plugins like prosemirror-autocomplete and prosemirror-codemark. If you would like to see something specific, open an issue or email, or try out the editor on Curvenote!

2022

  • Improve Markdown, Word and LaTeX export
  • Improve collaboration experience (cursors and highlights)
    • Possibly move to yjs as the collaboration backend
  • Improve configuration/extensibility
  • Improve/documentation integration demos
  • Improve math editor, adding a WYSIWYG math editor (likely as plugin)

Other ideas and plans

  • Integrate as a JupyterLab extension (would love help!!)
  • Integrate with ipywidgets (would love help!!)
  • Integrate with thebe (would love help!!)

Getting Started

git clone git@github.com:curvenote/editor.git
cd editor
npm install
npm run start