HN user

xatxat

382 karma

[ my public key: https://keybase.io/xat; my proof: https://keybase.io/xat/sigs/qikubdNOJxB_7RqKS87DoRuZLE5Slvfre1RE2WmFVuU ]

Posts38
Comments15
View on HN
blog.cloudflare.com 1y ago

Cloudflare Containers coming in June 2025

xatxat
32pts2
textrapper.medium.com 5y ago

What Gets Lost in the Crypto-Clone Wars

xatxat
2pts0
www.theverge.com 6y ago

Google Pixel 4 buyers won’t get unlimited photo uploads at original quality

xatxat
2pts0
www.atlassian.com 6y ago

Jira and Confluence: Upcoming Price Changes

xatxat
2pts1
www.k15t.com 6y ago

How to Rock Remote Work

xatxat
3pts0
www.youtube.com 7y ago

Say Hello to FarmBot Express and Express XL

xatxat
1pts0
www.wix.com 7y ago

Wix Corvid – Accelerated Development of Web Applications

xatxat
2pts0
electricbike-blog.com 7y ago

Custom Luna Apocalypse 2WD 10,000W 96v 50mph Electric Racing Kick Scooter (2017)

xatxat
2pts0
getkirby.com 7y ago

Introducing Kirby 3

xatxat
4pts0
www.picklewix.com 8y ago

Why don't people like Wix?

xatxat
3pts1
github.com 8y ago

Unstated – A simple state management library for React

xatxat
3pts0
www.citronresearch.com 8y ago

Citron Exposes the Dark Side of Shopify

xatxat
3pts0
techcrunch.com 8y ago

Electric scooter maker Gogoro raises $300M for growth

xatxat
2pts0
github.com 9y ago

Error boundaries in React v16

xatxat
3pts0
electrek.co 9y ago

Solar-powered eBikes could contribute to Africa’s economic development

xatxat
1pts0
electric-boarding.com 9y ago

10,0000W Electric Racing Kick Scooter

xatxat
12pts1
github.com 9y ago

React component composition cheatsheet

xatxat
1pts0
www.google.com 9y ago

React Conf Website does not appear in Google Search results

xatxat
1pts0
seekingalpha.com 9y ago

Tesla: Capital Raise Now, or Bankruptcy in 4 Months

xatxat
12pts3
24ways.org 9y ago

HTTP/2 Server Push and Service Workers: The Perfect Partnership

xatxat
2pts0
tylermcginnis.com 9y ago

React “Aha” Moments

xatxat
1pts0
github.com 9y ago

Cancelable Promises: Why was this proposal withdrawn?

xatxat
296pts213
github.com 9y ago

Dynamic import() proposol reaches stage 3

xatxat
1pts0
github.com 9y ago

Import() proposal for JavaScript

xatxat
2pts0
www.youtube.com 9y ago

Vue.JS – The Progressive Framework (Evan You)

xatxat
1pts0
www.youtube.com 9y ago

Evan You (Vue.JS): Demystifying Front End Framework Performance

xatxat
1pts0
github.com 10y ago

Socrates – Small (12kb), batteries-included redux stack

xatxat
3pts0
github.com 10y ago

Proposed JavaScript Standard Style

xatxat
29pts110
github.com 10y ago

Airtar – open source airdrop alternative

xatxat
2pts0
github.com 10y ago

Yo-yo.js – replacing react with 2 lines of code

xatxat
5pts2

congratulations on launching! we created a website builder for nft artists called butiq.art where we will test the simplehash api in the next weeks.

on a side note, if you ever need nft data for the tezos blockchain, feel free to shoot me a message. i developed an nft indexer that covers that chain very well.

I think people with enough experience in software development know quite well if the code they are currently writing is going to be testable or not.

I use this stack:

Frontend: React - Unstated (or just setState) - Axios - Plain CSS (with BEM notation) - Create React App - Prettier - Jest

Backend: Node.JS - Express - Knex - PostgreSQL - Tape

You can do that, but you will need to find a way to re-render the components which use that service, after something changed.

They are used to create arrays. You are able to subscribe to multiple containers:

  <Subscribe to={[CounterContainer, SomeOtherContainer]}>
      {(counter, someOther) => ()}
  </Subscribe>

Yeah, I agree that this is an edge case (nothing that I run into on a daily base) and the ContinentLists example might not be the best in this context. Something like a Dashboard with dynamic widgets would probably be a more realistic case.

I wouldn't store it as array in Redux because that would be too limiting (e.g. let's say I want a continent-list which is decoupled from the other continent-lists). If I would be forced to use redux in this case then I would create some random id for each ComponentList where I would store the UI state (but keep the continents data separated). Something like:

  {
    '<randomId>':
    {
        Asia:
        {
            collapsed: true
        }
    }
  }
IMHO this really makes things unnecessary complicated. It also makes it hard to re-use the ContinentsList component (maybe you want to use the same component in some other project which uses something else than redux?). I always try to think of the API of my react components first and how they later on can be easily reused. After I figured out the API of the react component then I might connect it to some store.

Probably the ContinentsList component would somehow look like this:

  <ContinentsList
    continents={<continents data>}
    renderItem={({ collapse, isCollapsed, continent }) => {
        return <ContinentItem onCollapseClick={collapse} isCollapsed={isCollapsed} continent={continent} />
    }}
  />

For example if you have multiple lists of continents and each one needs its own collapsed state. Maybe the user can even dynamically add/remove such continent lists in the UI. IMHO in most of these cases it's best to keep the continents data inside of redux and have the collapsed state being managed by the "ContinentsList" component.