News for hackers. Stuff that matters.
Re:The boring technology behind a one-person Internet compan... by Volrath89 on Tuesday September 17, 2019 @04:45AM (#20993005)
Completely agree. My default stack is now react + an api in the backend. The way you can reuse components is a great time saver (even for simple apps). I also like redux-thunk to separate all my API calls from the components. Makes everything very lean and readable.

I feel way more productive today than in the old jQuery, knockout messes

Re:The boring technology behind a one-person Internet compan... by jeremija on Tuesday September 17, 2019 @08:37AM (#20994231)
I've started to use TypeScript and React on the front end, with a JSON RPC middleware on an express server with helpers that automatically implement service interfaces for API calls, action creators and reducer handlers. And all of them are type-safe.

I've spent a lot of time building CRUD APIs and GraphQL interfaces, and this is the simplest solution that has saved me so much development time. JSON RPC gets so much hate, but it's made my life so much simpler.

Re:The boring technology behind a one-person Internet compan... by NohatCoder on Tuesday September 17, 2019 @11:52AM (#20996663)
Sounds neat, what project are you working on?
Re:The boring technology behind a one-person Internet compan... by jeremija on Wednesday September 18, 2019 @02:03AM (#21002725)
I'm currently working on various projects at work that I cannot discuss here, but in parallel I've been working on an express / TypeORM / React (SPA & SSR) framework that I hope to release one day as an open source project.

The main focus is to:

- easily share React components that use Redux state and actions between projects

- rapidly develop new server-side services and immediately use them in React components (by removing code duplication when it comes to creating action creators and action types)

- have type safety

- provide basic server-side and client-side components for basic user actions such as login, user profile, etc

- make it easy to write tests

And at some point in the future, I hope to make it generic enough so the libraries mentioned above can be swapped for other libraries, but that might be too much work :)

Re:The boring technology behind a one-person Internet compan... by NohatCoder on Wednesday September 18, 2019 @05:38AM (#21003612)
Sounds like a lot of work, how do you know that it is a net time saver?
Re:The boring technology behind a one-person Internet compan... by jeremija on Wednesday September 18, 2019 @08:53AM (#21004828)
Haha, I guess it is not at the moment, but it keeps me amused. In the first post I was just referring to using JSONRPC over standard REST endpoints as the time saver.
Re:The boring technology behind a one-person Internet compan... by r_singh on Tuesday September 17, 2019 @05:11AM (#20993132)
Same here! What's your choice of stack for the api?

PS - I need to build an api for an app with a React front-end. My choice of language is Python (because I'm super familiar and because of the great ORMs Python has).

Re:The boring technology behind a one-person Internet compan... by orhanhh on Tuesday September 17, 2019 @04:49PM (#20999920)
Django-rest-framework is super productive once you learn it. It has a bit of a learning curve, but it’s worth it if you are writing a lot of APIs, especially if you’re doing a lot of CRUD.

It’s my go to tool when I need to get stuff done. Combined with react and typescript, developing full stack is really smooth.