Skip to content

Commit

Permalink
Replace stock webpack hot dev client with CRA's (#328)
Browse files Browse the repository at this point in the history
* Close #284. Add custom error overlay and webpack client

* Bump and lockdown deps

* Add eslint, update webpackHotDevClient

* Change output fileName of client assets to bundle.xx

* Update typescript example with tslint

* Bump deps

* Bump reason deps

* Maintain sourcemap in prod
  • Loading branch information
jaredpalmer committed Aug 28, 2017
1 parent fc7c7a0 commit 5290b97
Show file tree
Hide file tree
Showing 25 changed files with 3,942 additions and 1,110 deletions.
9 changes: 5 additions & 4 deletions examples/basic/src/server.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import express from 'express';
import path from 'path';
import App from './App';
import React from 'react';
import express from 'express';
import { renderToString } from 'react-dom/server';
import App from './App';

const assets = require(process.env.RAZZLE_ASSETS_MANIFEST);

Expand All @@ -21,7 +20,9 @@ server
<meta charSet='utf-8' />
<title>Welcome to Razzle</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
${assets.client.css ? `<link rel="stylesheet" href="${assets.client.css}">` : ''}
${assets.client.css
? `<link rel="stylesheet" href="${assets.client.css}">`
: ''}
<script src="${assets.client.js}" defer></script>
</head>
<body>
Expand Down
1 change: 1 addition & 0 deletions examples/with-reason-react/bsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
an issue! */
{
"name": "razzle-reason",
"bsc-flags": ["-bs-no-version-header", "-bs-super-errors"],
"reason": {
"react-jsx": 2
},
Expand Down
2 changes: 1 addition & 1 deletion examples/with-reason-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"reason-react": "^0.1.5"
},
"devDependencies": {
"bs-platform": "latest",
"bs-platform": "^1.9.1",
"razzle": "^0.7.6-rc2"
}
}
Loading

0 comments on commit 5290b97

Please sign in to comment.