• Stars
    star
    197
  • Rank 197,722 (Top 4 %)
  • Language
    Objective-C
  • License
    BSD 2-Clause "Sim...
  • Created about 11 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

An event-based parser for markdown text

DTMarkdownParser

Build Status

This is a parser for Markdown-formatted text. It follows the following design guidelines:

  • No C-library dependency
  • Event-based, similar to NSXMLParser
  • Fully unit-tested (incl. code coverage)
  • Supporting OS X and iOS

It’s a goal for this project to be developed using “test-driven development” (TDD). This is fancy talk for “write the unit test first, then code the implementation”.

Another is to, at some point in the not-too-distant future, provide input for DTCoreText to allow generating NSAttributedStrings directly from Markdown. Therefore the delegate protocol uses metaphors similar to those found in DTHTMLParser.

Contributing to the Project

Contributions are welcome, provided you use the following workflow:

  1. Create new unit tests for features you add (see DTMarkdownparserTest for examples)
  2. All submissions are unit tested on Travis-CI and are only merged if all existing unit tests pass
  3. Please create an issue on GitHub before starting to code
  4. Work on a feature branch named like your_name/issue_123.
  5. Only submit pull requests against the develop branch
  6. When in doubt, just ask

License

This project is covered by a BSD 2-clause license. If you use it in a published app, you have to give some form of credit to Cocoanetics (like on your About screen). This requirement is lifted if you procure a Non-Attribution License from us.

Implemented

  • Basic Text
  • Emphasis (strong, em)
  • Strikethrough
  • Inline Code
  • Indented Code
  • Fenced Code (GitHub-style)
  • Horizontal Rule
  • Headers
  • Hyperlinks (inline and reference)
  • Images (inline and reference)
  • Linebreaks Handling (GitHub versus Gruber)
  • Lists (ordered or unordered)
  • Lists (stacked)
  • Forced linking via angle brackets
  • Automatic Linking of URLs (web and mail)

To Do

  • Character Escaping
  • Inline HTML (? should we ever do this ?)
  • Multi-level Quoting and Code Blocks
  • Additional Useful Markdown Extensions:
    • MultiMarkdown Table support
  • Proper Reporting of applicable processed range of text, e.g. to use for syntax highlighting

Markdown References

More Repositories

1

DTCoreText

Methods to allow using HTML code with CoreText
Objective-C
6,343
star
2

DTFoundation

Standard toolset classes and categories
Objective-C
802
star
3

DTRichTextEditor

A rich-text editor for iOS
Objective-C
354
star
4

DTBonjour

Framework for Communicating over Bonjour+Wifi
Objective-C
340
star
5

Kvitto

App Store Receipt Validation
Swift
295
star
6

Examples

Sample projects that usually go with a blog post
Objective-C
213
star
7

DTLocalizableStringScanner

An open source substitute for Apple's genstrings which can be integrated in Apps.
Objective-C
109
star
8

DTWebArchive

A lightweight class to allow interaction with the WebArchive Pasteboard type used by Apple's iOS apps
Objective-C
107
star
9

BarCodeKit

A modern framework for generating 1D barcodes
Objective-C
87
star
10

AutoIngest

Automatic Sales Report Downloader for Mac
Objective-C
86
star
11

DTITCReportDownloader

A rewrite of Apple's Autoingest.java in Objective-C
Objective-C
81
star
12

DTDownload

File Downloading, Caching and Queueing
Objective-C
80
star
13

Swift-Examples

Cocoanetics Swift Examples
Swift
66
star
14

RadarSamples

Samples For Demonstrating Bug Reports
Objective-C
49
star
15

NSTimeZone-Localization

Providing a localized translation for the geopolitical names in the NSTimeZone class.
Objective-C
39
star
16

DTLoupe

Reimplementation of the iOS magnifying glass
Objective-C
38
star
17

DTKeychain

A simple and modern keychain wrapper
Objective-C
30
star
18

DTOAuth

A Simple OAuth Client
Objective-C
27
star
19

DTPDF

DTPDF
Objective-C
27
star
20

POEditorAPI

An API and Command-line Tool for POEditor.com
Swift
16
star
21

Ruby

Collection of my Ruby Scripts
Ruby
15
star
22

XLIFFix

Utility for recreating strings file from XLIFF
Swift
13
star
23

Barcodes_with_iOS

Sample Source Code for the Book "Barcodes with iOS" published by Manning
Objective-C
13
star
24

DTMorseKeyboard

A custom inputView that accepts Morse Code
Objective-C
12
star
25

DTXMLRPC

Wrapper for XML-RPC APIs
Objective-C
11
star
26

Pebble

Pebble Projects
C
8
star
27

GradleHelpers

1
star