mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-28 20:25:33 +08:00
Make the publish script faster by not converting all the files on every file
This commit is contained in:
@@ -9,10 +9,9 @@ var slugify = require('slugify');
|
||||
var Header = React.createClass({
|
||||
render: function() {
|
||||
var slug = slugify(this.props.toSlug || this.props.children);
|
||||
var H = React.DOM['h' + this.props.level];
|
||||
|
||||
return this.transferPropsTo(
|
||||
<H>
|
||||
var H = 'h' + this.props.level;
|
||||
return (
|
||||
<H {...this.props}>
|
||||
<a className="anchor" name={slug}></a>
|
||||
{this.props.children}
|
||||
{' '}<a className="hash-link" href={'#' + slug}>#</a>
|
||||
|
||||
Reference in New Issue
Block a user