convert to ES2015 imports
This commit is contained in:
parent
2f882ae8cd
commit
6d981c6fdf
@ -1,7 +1,8 @@
|
|||||||
const express = require('express'); // CommonJS module syntax
|
import express from 'express';
|
||||||
const React = require('react');
|
import React from 'react';
|
||||||
const renderToString = require('react-dom/server').renderToString;
|
import { renderToString } from "react-dom/server";
|
||||||
const Home = require('./client/components/Home').default;
|
import Home from './client/components/Home'
|
||||||
|
|
||||||
const app = express();
|
const app = express();
|
||||||
|
|
||||||
app.get('/', (req, res) => {
|
app.get('/', (req, res) => {
|
||||||
|
Loading…
Reference in New Issue
Block a user