Skip to content

Commit

Permalink
Merge pull request #33 from holidayextras/callback
Browse files Browse the repository at this point in the history
Updating to support callback
  • Loading branch information
Richard Stevens authored Jan 29, 2018
2 parents 85b1fe3 + 5768331 commit 8d2e41d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 27 deletions.
15 changes: 1 addition & 14 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,16 +1,3 @@
{
"presets": [
"react",
["env", {
"target": {
"browsers": [
"not ie <= 8",
"last 2 iOS major versions",
"last 2 Firefox major versions",
"last 2 Safari major versions",
"> 10% in UK"
]
}
}]
]
"presets": ["es2015", "react"]
}
21 changes: 10 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@holidayextras/static-site-generator",
"version": "7.0.2",
"version": "6.2.7",
"description": "Holiday Extras Static Site Generator in metalsmith / react",
"repository": {
"type": "git",
Expand Down Expand Up @@ -34,25 +34,24 @@
"debug": "^2.2.0",
"jsonp": "^0.2.0",
"meta-marked": "^0.4.0",
"metalsmith": "^2.3.0",
"metalsmith": "^1.3.0",
"metalsmith-assets": "^0.1.0",
"metalsmith-markdown": "^0.2.1",
"metalsmith-react-tpl": "^2.0.0",
"metalsmith-react-tpl": "^1.0.0",
"mkdirp": "^0.5.1",
"moment": "^2.11.1",
"prismic.io": "^3.1.3",
"publish": "^0.5.0",
"react": "^16.0.0",
"react-dom": "^16.0.0",
"react-redux": "^5.0.6",
"redux": "^3.7.2",
"react": "^0.14.3",
"react-dom": "^0.14.3",
"react-redux": "^5.0.4",
"underscore": "^1.8.3"
},
"devDependencies": {
"babel-cli": "6.7.7",
"babel-core": "^6.26.0",
"babel-preset-env": "^1.6.0",
"babel-preset-react": "^6.24.1",
"babel-core": "^6.8.0",
"babel-preset-es2015": "^6.6.0",
"babel-preset-react": "^6.5.0",
"brace-expansion": "^1.1.7",
"grunt": "^0.4.5",
"grunt-contrib-uglify": "^0.11.0",
Expand All @@ -61,6 +60,6 @@
"npm-watch": "^0.1.8",
"rimraf": "^2.2.8",
"standard": "^10.0.2",
"webpack": "^3.6.0"
"webpack": "^1.13.2"
}
}
4 changes: 2 additions & 2 deletions src/webpackPages.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ const webpackPages = (globalOptions) => {
output += 'var store = require( \'' + props.store + '\' );'
output += 'window.ReactRootProvider = Provider;'
output += 'window.ReactRootStore = store;'
output += 'var renderedElement = ReactDOM.hydrate( <Provider store={ store }><Element {...props} /></Provider>, document.getElementById( \'content\' ));'
output += 'var renderedElement = ReactDOM.render( <Provider store={ store }><Element {...props} /></Provider>, document.getElementById( \'content\' ));'
} else {
output += 'var renderedElement = ReactDOM.hydrate( <Element {...props} />, document.getElementById( \'content\' ));'
output += 'var renderedElement = ReactDOM.render( <Element {...props} />, document.getElementById( \'content\' ));'
}

const destFilename = options.destFilename
Expand Down

0 comments on commit 8d2e41d

Please sign in to comment.