This project provides a basic starting point for developing a React-based application that can be rendered in an Amplenote embed.
- Fork this repo, choosing a repo name appropriate to the plugin you will build.
git clone
your forked repo, following GitHub's instructions- Install dependencies with
yarn install
- Create a build with
yarn build
The output of the build step is a zip file containing a markdown note that can be used as a plugin note in Amplenote. Import this zip file as a markdown archive in Amplenote and enable it as a plugin in your Amplenote account. The zip file contains an attachment containing the potentially-large plugin code, to avoid creating an extremely large note.
The following plugin actions are implemented in the plugin:
appOption
triggering the plugin via the quick open menu will open a sidebar embed for the pluginrenderEmbed
handles rendering the sidebar embed, rendering this application in the sidebaronEmbedCall
called whenwindow.callAmplenotePlugin
is called from the embed code in this project
The renderEmbed
action output by this plugin can remain unchanged in the final plugin, but it's likely that the
appOption
and onEmbedCall
actions will need to be customized to fit the needs of the final plugin.
Run yarn dev
to serve the application locally, with automatic reloading on filesystem changes.