Now Particularly Misnamed
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »


1.0.3 • Public • Published

Sir Trevor

Rich content editing entirely re-imagined for the web

Sir Trevor in action

Main project conceived by Andrew Sprinz. Maintained by Chris Bell & Andrew Walker.

This fork is maintained by Glints to work primarily with markdown, amongst other customizations, to suit our use case more specifically.

Quick start

Full documentation can be found here.

Plain JS

  • Download the latest release
  • ...or clone the repo: git clone git://
  • ...or install with Bower bower install sir-trevor-js


  1. Sir Trevor Rails
  2. Umbraco 7, Umbraco 6
  3. CakePHP
  4. Wordpress
  5. Laravel
  6. Django
  7. Yii Framework
  8. Symfony2

Custom blocks

We are keeping a list of custom block repos here. See the documentation to find out more about adding your own block types.

Browser support

Sir Trevor is only tested on the following modern browsers:

  • IE10+
  • Chrome 25+
  • Safari 5+
  • Firefox 16+

ECMAScript 6 shims are bundled in by default; if the platform you wish to run on doesn't support ECMAScript 5 APIs you'll need to shim those yourself.


It's up to you:

  • Bring your own jQuery or Zepto (and have it put itself on window.$) and use sir-trevor.js / sir-trevor.min.js
  • Or if you're using Browserify yourself, npm install sir-trevor and require('sir-trevor') it as you would expect.


See the roadmap and read a little about the philosophy guiding development.

Customising the way it looks

We use Sass for our styles, if you'd like to change the default styling please fork the repository and make changes to the Sass before recompiling.

Customising blocks

Block Types can also easily be added to the SirTrevor.Blocks object. You can also override the default block types (Text, Image, Tweet, Video, Quote, Heading & List) at any time. See the documentation to find out more about adding your own block types.


Before getting started please be sure to install the necessary dependencies via npm:

$ npm install

When completed, we have a couple of preset scripts:

$ npm run dev

This compiles for development, and watches source files to recompile when you change something.

$ npm test

Runs the linter and test suite, just like the CI server does.

$ npm run dist

Concatenates scripts, compiles the Sass, runs the Jasmine tests and minifies the project.

Please ensure any pull requests have relevant Jasmine tests (where applicable).


Sir Trevor is released under the MIT license:




npm i glints-sir-trevor

Downloadsweekly downloads









last publish


  • avatar
Report a vulnerability