Pretty much... doesn't bug me too much, but an annoyance all the same. Need to remember to take a look from home as I'm interested in seeing the video. May look to see if it's been cross-posted to youtube.
Yeah, it's a mixed bag, I usually wrap it up in something that works with my API structure better... (posting a gist to link now). The normalizeRequest[1] default export handles a lot of the issues for me. (note using elvis operator[2] via babel).
With that in place, a lot of my api-client comes down to things like:
import callAPI, { headRequest } from './request';
export const check = id =>
headRequest(`/petition/${encodeURIComponent(id.toUpperCase())}`).then(
r => r && r.statusCode === 200
);
export const dashboard = id =>
callAPI('GET', `/petition/${encodeURIComponent(id.toUpperCase())}/dashboard`);
export const create = petition => callAPI('POST', '/petition', petition);
[1] https://gist.github.com/tracker1/0b0522b840573171edffd31df50b381a
[2] https://babeljs.io/docs/en/babel-plugin-proposal-optional-chaining
If using material-ui, you will likely want to look at `mdi-material-ui` which is an icon package for material-ui using https://materialdesignicons.com/ which is more complete than the official icon library used by material-ui/icons.
Personally material-ui with react itself is hands down my favorite UI toolkit by a large margin. It's consistent, easy to use and customize, and everything from the components to the theming are working with the larger npm/react ecosystem instead of the NIH you get from other frameworks.
For me, I tend to put `node-fetch` onto `global.fetch` so that it's generally available like in modern browsers. If you have to support older browsers, could always use `isomorphic-fetch` for shared modules. I prefer to assume it's globally available and write to that.
It's not exactly the same, but close enough that I rarely have issue with client-server modules.
Nice... another heavy hitter using React not mentioned in the article would be Walmart, who has done a lot for optimized server/client and doughnut rendering.
While cool... much like ngrx, this is emphatically no longer redux in my mind, and shouldn't be labelled as such. There are a lot of similar frameworks, and they are cool but I can't help but feel they are trying to piggy back a different pattern off of redux's success.