<commit_before>cobalt editor
- npm / bower / grunt installeren
- requirejs oid toevoegen
- fast render door immutable data -> volledige render 1 keer doen, bij creatie


simplified html
h1/h2/h3/p/ol/ul/blockquote
em/strong/a

cobalt.html = (function(self) {
	
	var rules = {
		block: ['h1','h2','h3','p','ol','ul','li','blockquote','br'],
		inline: ['em','strong','a'],
		obligatoryChild: {
			'ol': ['li'],
			'ul': ['li']
		},
		obligatoryParent: {
			'li': ['ol','ul']
		}
	};
	rules.alltags = rules.block.concat(rules.inline);
	rules.nesting: {
		'h1': rules.inline,
		'h2': rules.inline,
		'h3': rules.inline,
		'p': rules.inline.concat(['br']),
		'ol': ['li'],
		'ul': ['li'],
		'blockquote': rules.alltags,
		'br': [],
		'em': rules.inline,
		'strong': rules.inline,
		'a': rules.inline.filter(function(tag) { return tag!='a'; }
	};
	rules.toplevel = rules.block.filter(function(tag) { return tag!='li';});
	

	self.renderFragment = function(fragment) {
		var result = '';
		
		return result;
	};

})(cobalt.html || {});<commit_msg>Added html render start<commit_after>cobalt.html = (function(html) {
	
	var rules = {
		block: ['h1','h2','h3','p','ol','ul','li','blockquote','br'],
		inline: ['em','strong','a'],
		obligatoryChild: {
			'ol': ['li'],
			'ul': ['li']
		},
		obligatoryParent: {
			'li': ['ol','ul']
		}
	};
	rules.alltags = rules.block.concat(rules.inline);
	rules.nesting: {
		'h1': rules.inline,
		'h2': rules.inline,
		'h3': rules.inline,
		'p': rules.inline.concat(['br']),
		'ol': ['li'],
		'ul': ['li'],
		'blockquote': rules.alltags,
		'br': [],
		'em': rules.inline,
		'strong': rules.inline,
		'a': rules.inline.filter(function(tag) { return tag!='a'; }
	};
	rules.toplevel = rules.block.filter(function(tag) { return tag!='li';});
	

	html.cobaltToHtml = function(fragment) {
		var result = '';
		
		return result;
	};

    html.cobaltToDom = function(fragment, dom) {
        
    };
        
    html.cobaltDomToHtmlDom = function(relativeFragment, dom) {
        // cobalt fragment with relative offsets and links to html nodes to html dom
        // cobalt dom serves as a shadow dom for the html dom
    };
        
    html.htmlToCobalt = function(htmlString) {
      
        return fragment;
    };
        
})(cobalt.html || {});
{'fraction_non_alphanumeric': 0.21038732394366197, 'fraction_numerical': 0.007042253521126761, 'mean_word_length': 3.3965183752417794, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3555633', 'n_tokens_mistral': 919, 'n_tokens_neox': 842, 'n_words': 168}