Skip to content

Instantly share code, notes, and snippets.

@stovv
Last active March 22, 2020 01:14
Show Gist options
  • Select an option

  • Save stovv/5b4e9229b5595f038a43f0ed6f8a9f5c to your computer and use it in GitHub Desktop.

Select an option

Save stovv/5b4e9229b5595f038a43f0ed6f8a9f5c to your computer and use it in GitHub Desktop.
Dynamic import NextJS
import React from 'react';
import dynamic from 'next/dynamic'
class Editor extends React.Component {
render(){
let RedactorSSRSafe = dynamic(import('../redactor.react'), {
ssr: false
});
return (<RedactorSSRSafe/>);
}
}
export default Editor;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment