Skip to content

Instantly share code, notes, and snippets.

View jochienabuurs's full-sized avatar
🏠
Working from home

Jochem Nabuurs jochienabuurs

🏠
Working from home
View GitHub Profile
@jochienabuurs
jochienabuurs / index.js
Created December 28, 2018 12:39 — forked from cereallarceny/index.js
Server-side rendering in Create React App
const md5File = require('md5-file');
const path = require('path');
// CSS styles will be imported on load and that complicates matters... ignore those bad boys!
const ignoreStyles = require('ignore-styles');
const register = ignoreStyles.default;
// We also want to ignore all image requests
// When running locally these will load from a standard import
// When running on the server, we want to load via their hashed version in the build folder