express wildcard
This commit is contained in:
parent
fb64977d06
commit
c5d7d4b275
@ -6,6 +6,7 @@ export default () => {
|
||||
return (
|
||||
<div>
|
||||
<Route exact path="/" component={Home} />
|
||||
<Route exact path="/hi" component={() => 'Hi'} />
|
||||
</div>
|
||||
) ;
|
||||
};
|
@ -4,7 +4,7 @@ import renderer from './helpers/renderer';
|
||||
const app = express();
|
||||
|
||||
app.use(express.static('public'));
|
||||
app.get('/', (req, res) => {
|
||||
app.get('*', (req, res) => {
|
||||
res.send(renderer(req));
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user