Feel free to contact me at robert.balicki@gmail.com or tweet at me @statisticsftw
This is a rough outline of how we utilize next.js and S3/Cloudfront. Hope it helps!
It assumes some knowledge of AWS.
| const bypass = [ | |
| // function names to avoid logging | |
| ]; | |
| const collapsed = [ | |
| // function names to groupCollapsed | |
| ]; | |
| module.exports = function(babel) { | |
| const { types: t } = babel; | |
| const wrapFunctionBody = babel.template(`{ |
Feel free to contact me at robert.balicki@gmail.com or tweet at me @statisticsftw
This is a rough outline of how we utilize next.js and S3/Cloudfront. Hope it helps!
It assumes some knowledge of AWS.
| // This is an advanced example! It is not intended for use in application code. | |
| // Libraries like Relay may make use of this technique to save some time on low-end mobile devices. | |
| // Most components should just initiate async requests in componentDidMount. | |
| class ExampleComponent extends React.Component { | |
| _hasUnmounted = false; | |
| state = { | |
| externalData: null, | |
| }; |
| // determine if in-browser or using node.js | |
| // thruthy | |
| var _nodejs = ( | |
| typeof process !== 'undefined' && process.versions && process.versions.node); | |
| if (_nodejs) { | |
| _nodejs = { | |
| version: process.versions.node | |
| }; | |
| } |
| /* eslint-disable prefer-template */ | |
| const path = require('path'); | |
| const aliases = require('./aliases'); | |
| // /////////////////////////////////////////////////////////////// | |
| // ////////////////// PLUGINS //////////////////////////////// | |
| // /////////////////////////////////////////////////////////////// | |
| const commonPlugins = [ |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.