reenable code splitting for react-syntax-highlighter package

This commit is contained in:
Sebastian Sdorra
2019-10-17 14:32:55 +02:00
parent 0dc1af2f47
commit bd35a63acf
2 changed files with 3 additions and 7 deletions

View File

@@ -1,11 +1,7 @@
// @flow
import React from "react";
// TODO fix code splitting in production
// Storybook does not like the LightAsync import:
// import { LightAsync as ReactSyntaxHighlighter } from "react-syntax-highlighter";
// so we should use the default import for development and the LightAsync for production
import ReactSyntaxHighlighter from "react-syntax-highlighter";
import { LightAsync as ReactSyntaxHighlighter } from "react-syntax-highlighter";
import { arduinoLight } from "react-syntax-highlighter/dist/cjs/styles/hljs";
type Props = {