# ContentCompiler

Utilclass for compiling

## Constructor

#### new ContentCompiler($, logger)

##### Parameters:

`$` ( cheerio )
`logger` ( Logger )

Source:
  - lib/ContentCompilerer.js.js, line 10

### Methods

#### (private) ._generateGrid($, rowSrc, columns, isLG) → {this|void|jQuery}

##### Parameters:

`$` ()
`rowSrc` ()
`columns` ()
`isLG` ()

Source:
  - lib/CompileHelperper.js, line 196

#### (private) .alignmentHelper($, selector, direction)

Handles floats and centered elements

##### Parameters:

`$` ( cheerio )
`selector` ( string )
`direction` ( 'left' | 'center' | 'right' )

Source:
  - lib/ContentCompiler.jsjs.js, line 116

#### (private) .divHelper($)

Replaces all divs with tables

##### Parameters:

`$` ( cheerio )

Source:
  - lib/ContentCompilerer.js.js, line 22

#### (private) .gridHelper($, columns)

Replaces rows and columns to tables and set according separators

##### Parameters:

`$` ( cheerio )

ElementHelper in which the rows and cols should be replaced

`columns` ( number )

Amount of allowed columns in a row

Source:
  - lib/CompileHelperper.js, line 175

#### (private) .marginHelper($)

Replaces all margin classes to equivalent spacer elements

##### Parameters:

`$` ( cheerio )

Source:
  - lib/ContentCompilerer.js.js, line 46

#### (private) .paddingHelper($)

Handles all padding classes. If padding-element is not a table, wrap a table around

##### Parameters:

`$` ( cheerio )

Source:
  - lib/ContentCompilerer.js.js, line 78

#### (private) .preview($)

Replaces preview tag with hidden div and extend content to 100 characters

##### Parameters:

`$` ( cheerio )

Source:
  - lib/CompileHelperper.js, line 158

#### (private) .tableHelper($)

Adds border, cellspacing and cellpadding attributes to all table elements

##### Parameters:

`$` ( cheerio )

Source:
  - lib/CompileHelperper.js, line 141