Dillon de Voor (@CrocoDillon) profile picture

Freelance JavaScript Developer

The Netherlands
Joined October 2010
Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)Photo by Dillon de Voor (@CrocoDillon)
How would you remember a value that shouldn't change at all during the lifetime of a React component? `useMemo` doesn't give that guarantee. const x = useRef(new X()) const [x] = useState(() => new X()) Something (perhaps more obvious) I completely missed? cc @dan_abramov
1
My wish for JavaScript in 2021; the nullish default operator. Useful for functions with multiple optional arguments or when dealing with optional props in React components where passing null instead of undefined is a common practice 😄 @carbon_app
1
Examples are often easier to read than documentation. Thanks to this example I now sort of understand React hooks 😅 Though... stateful functional components? o_0
ok so - I took dan's classes/hooks code from react conf, blacked out the 'unnecessary' bits, then colour coded bits by 'concern'. so much nicer. the effect is amplified in more complex components, where concerns are split and mixed across lifecycle methods.
2
Still my favorite bookmark to get rid of `position: fixed` elements blocking a page: javascript:(function(){document.body.style.transform='translate(0,0)'}());
Semi-mocked React context for use in your (Enzyme) component tests. Good idea or not? cc @dan_abramov
I feel like a noob but why don't <a> and <button> elements, styled identically, align? codepen.io/CrocoDillon/pen/g…
1
Been a while since I made something I'm proud of on @CodePen... this is a component that highlights certain tokens in an (search query) input (in this case OR and AND but can be easily expanded) 🙃 codepen.io/CrocoDillon/pen/m…
2
Material Design finally has a reference implementation (including web), been waiting for this! material.io/components/
Because I'm better at coding than drawing... "Declarative SVG paths using React", interesting or terrible idea? PoC: codepen.io/CrocoDillon/pen/M…
one I'm still guilty of, reinventing the wheel (or trying to at least). You learn lots of stuff but productivity sucks.
1
100% code coverage requirement for tests, unit testing implementation details, flow typing all the things, mixins, global css.
1
maybe because the voice of people who complain is so much louder than the voice of people who are satisfied.
2
`document.all` is weird (one of those “what the flux?” browser quirks) codepen.io/CrocoDillon/pen/y…
1
1
Nice visualization of how distributed consensus work (write concern, replication etc) thesecretlivesofdata.com/raf…
there is nothing "wrong" with JavaScript developers. Can't hurt to joke from time to time though :)
“I Peeked Into My Node_Modules Directory And You Won’t Believe What Happened Next”, awesome read! ;D medium.com/friendship-dot-js…
4
5
Checked out the website of this cool project #FarmBot and what do you know, they use @reactjs :D