Skip to content
This repository has been archived by the owner on Oct 18, 2021. It is now read-only.
/ markd Public archive

Super duper experimental lightweight customizable jquery plugin markdown editor.

License

Notifications You must be signed in to change notification settings

dbmedialab-archive/markd

Repository files navigation

#Markd README

Super duper experimental lightweight customizable jquery plugin markdown editor. Try it out.

##Dependecies

##Usage

Html:

<textarea id="editor" data-markd># Heading</textarea>
<!-- or -->
<div id="editor" data-markd contenteditable># Heading</div>

Javascript:

$('#editor').markd();

###Options (defaults)

$('#editor').markd({
	kbd: {						// Keyboard command mappings.
		bold: 		'mod+b',	// Passing empty objects disables 
		italic: 	'mod+i',	// all keyboard commands.
		code: 		'mod+k',
		link: 		'mod+l',
		help:		'mod+h',
	},
	toolbar: ['b','i','q','l'] // Sequence of buttons in the toolbar.
});

###Public methods

$('#editor').markd('getContent');
  • markd('getContent') - returns the editors content
  • markd('setContent', 'some text') - set the editors content
  • markd('setCursor', 10) - place the cursor somewhere in the editor

About

Super duper experimental lightweight customizable jquery plugin markdown editor.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published