public function parse($text = '', $options = []) {
		// Extend default options
		$options = array_merge([
			'config'	=> [],
			'purifier'	=> true
		], $options);

		// Parsedown Extra
		$markdown = parent::text($text);

		// HTML Purifier
		if (config('parsedownextra.purifier.enabled') && $options['purifier']) {
			$purifier = app(HTMLPurifierLaravel::class);

			// Filter HTML
			$markdown = $purifier->purify($markdown, $options['config']);
		}

		return $markdown;
	}
public function parse($text = '', $options = []) {
		// Extend default options
		$options = array_merge([
			'config'	=> [],
			'purifier'	=> true
		], $options);

		// Parsedown Extra
		$markdown = parent::text($text);

		// HTML Purifier
		if (config('parsedownextra.purifier.enabled') && $options['purifier']) {
			$purifier = app(HTMLPurifierLaravel::class);

			// Filter HTML
			$markdown = $purifier->purify($markdown, $options['config']);
		}

		return $markdown;
	}
public function parse ( $ text = '' , $ options = [ ] ) { // Extend default options $ options = array_merge ( [ 'config' => [ ] , 'purifier' => true ] , $ options ) ; // Parsedown Extra $ markdown = parent :: text ( $ text ) ; // HTML Purifier if ( config ( 'parsedownextra.purifier.enabled' ) && $ options [ 'purifier' ] ) { $ purifier = app ( HTMLPurifierLaravel :: class ) ; // Filter HTML $ markdown = $ purifier -> purify ( $ markdown , $ options [ 'config' ] ) ; } return $ markdown ; }
Convert Markdown text to HTML and sanitize the output.

@see \Parsedown::parse()

@param string	$text		The Markdown text to convert.
@param array		$options	Options for HTML Purifier.

@return string The resulting HTML from the Markdown text conversion.
Convert Markdown text to HTML and sanitize the output .