Skip to content

Instantly share code, notes, and snippets.

View artginzburg's full-sized avatar
🤍
const crazy = new Genius();

Arthur Ginzburg artginzburg

🤍
const crazy = new Genius();
View GitHub Profile
@artginzburg
artginzburg / toClassNames.js
Last active July 27, 2021 08:50
Perfectly valid React className from an Array · without falsy values
export const toClassNames = (arr) => arr.filter(Boolean).join(' ');
export const classNames = (arr) => ({ className: toClassNames(arr) });

GitHub Pages + React Router

The whole setting prevents static routing from ruining the UX by synchronizing your production and development implementations, so they act identically and effectively.

Just type git.io/gh-pages-with-react-router to go here

TL;DR

# package.json