Skip to content

RaspberryPiFoundation/rpf-markdown-core

Repository files navigation

rpf-markdown

JS library to parse markdown and return HTML

Installation: Currently the library is not published anywhere. Follow these steps to install locally:

  1. Pull this repository
  2. Run yarn build
  3. Run yarn pack - This will create a file called rpf-markdown-core-v1.0.0.tgz
  4. Copy this file into the repo you want to install at.
  5. Run yarn install <path-to-tgz-file> to install in the target repo.

Current features:

  • Code blocks formatted using prism JS
  • projects site custom blocks like task, tip and debug
  • scratchblocks
  • Raspberry Flavoured Markdown as outlined in this spec

Example usage:

import { processEditorProject } from "rpf-markdown-core";

const exampleMarkdown = `# Hello World`;

// processEditorProject returns the HTML for the markdown passed into it.
const htmlOutput = processEditorProject(exampleMarkdown);

Releasing a new version

  1. Create a new PR to bump the version in package.json
  2. Merge the PR
  3. Create a new Release with a new tag matching the version in package.json
  4. New version of package should be published automatically

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors