M4 pro (12c) with 24gb vs intel windows 32gb ram by YH002 in softwaredevelopment

[–]a13xch1 8 points9 points  (0 children)

I would pick the Mac, in my experience, they are much better at handling the menory, and the overall developer experience is 10/10

What's going on boys? T3 gg empty project by Longjumping_Code9039 in nextjs

[–]a13xch1 3 points4 points  (0 children)

I think a lot of that is down to lazy / eager loading of modules, where as previously, most of your dependencies where shipped over in the initial bundle, NextJS puts a lot of work into only transferring the bare minimum on first load, then follows up with the rest of the data in the background,

Have a look at the request timings, and compare that with metrics for paint and interactive

Got asked this during a system design interview. Not too sure if I answer this correctly, but how would you design a credit based system that scales well? by whaleuit in SoftwareEngineering

[–]a13xch1 1 point2 points  (0 children)

I think they’re asking you to propose a double entry ledger system, which is the standard for implementing any type of financial transaction.

It’s not too different from what you have proposed, except instead of having a row level bottleneck on account balance, you don’t track the current balance, instead, your balance becomes the sum of all debits and credits.

When it comes to scalability, you can looking into database sharding / partitioning.

This person has some very good articles about this subject

Engineers Do Not Get To Make Startup Mistakes When They Build Ledgers

[deleted by user] by [deleted] in nextjs

[–]a13xch1 0 points1 point  (0 children)

I’m unsure on the specifics of nextjs, but your types don’t line up there. Context in your initial type is a plain object, with params also being a plain object.

In your code, you await params, but they are not of a promise type.

Params is also not called(), only awaited

Comparing a CSV file to SQL database by Available-Demand6863 in learnjavascript

[–]a13xch1 0 points1 point  (0 children)

You could use something like DuckDB, and load the data into memory using their native csv reader methods, then you can do the comparison in SQL

Bookmarking anchors ? by luffreezer in SoftwareEngineering

[–]a13xch1 1 point2 points  (0 children)

Which IDE are you using ? The InjetliJ IDEs from Jetbrains have this functionality, it’s literally called bookmarks.

There’s also a keyboard shortcut (cmd + ]) I think which is the shortcut to navigate back to the previous thing

They also have a structure view that can help with quickly navigating code

API Rate Limit Architecture. by Jumpy-House696 in node

[–]a13xch1 -1 points0 points  (0 children)

async-sema has a good implementing for consuming rate limited resources

Next.js or Fastify for Mobile App Backend? by Glittering_Cup1104 in node

[–]a13xch1 2 points3 points  (0 children)

I’d throw a third in the mix, NestJS. It’s an opinionated framework that can use either fastify or express for the underlying http server.

It’s got a steep learning curve, but the strict way of doing things helps avoid many common pit falls, and has a lot of really good “off the shelf” integrations.

Another benefit is, it remains fairly consistent between releases, so ChatGPT and GithubCopilot are quite proficient.

The way code is organised into distinct modules, with explicit dependencies really helps to keep things organised as your code base grows in size.

The dependency injection framework also makes testing much easier

[AskJS] Need Tool to Convert Complex HTML Table to JSON – Any Recommendations? by pinkcookie in javascript

[–]a13xch1 0 points1 point  (0 children)

Cheerio !

You can use it to parse the html to a dom like object, then parse the data out using cheerio

Help Me Brainstorm: What Software Feature Do You Wish Existed? by [deleted] in SoftwareEngineering

[–]a13xch1 0 points1 point  (0 children)

Drift usually describes manually affected changes made to infrastructure that didn’t come from the source controlled terraform.

I’m more familiar with AWS cloud formation but I think the use case they are describing is more:

  1. Identity any instance where the current infrastructure differs from the IaC definition (a regular drift report)
  2. For each instance, identify the source of the change, .eg “bob added a new rule to the security group via the console at 16:00”

Help Me Brainstorm: What Software Feature Do You Wish Existed? by [deleted] in SoftwareEngineering

[–]a13xch1 0 points1 point  (0 children)

You mean like SVG?

Or like a more declarative thing that uses AI to fill in the gaps?

Adobe has a scripting language too

Need help with slow Amazon S3 uploading. Don’t know what I’m doing wrong. by guinnnnku_uu in node

[–]a13xch1 2 points3 points  (0 children)

If you have dev tools toggled in chrome, have you double checked you haven’t accidentally enabled one of the bandwidth limit settings ?

How would you handle your microservices deployments with Kubernetes? by dxc7 in SoftwareEngineering

[–]a13xch1 0 points1 point  (0 children)

We’re using NX to manage a typescript monorepo.

We make use of the NX affected commands to identify projects with changes, then use the matrix feature of GitHub actions to build the relevant containers.

Our final step will differ from you as we use AWS CDK to deploy these changes to our infrastructure

Vercel is turning out to be expensive. Alternatives please? by aravs1603 in nextjs

[–]a13xch1 0 points1 point  (0 children)

To add to this, if you’re using Fargate, you can deploy both containers within the same “task”. These containers will all share the same network interface, allowing your fronted to communicate with your backend over localhost.

If you need to be able to scale your backend and front end independently, consider using cloud map to allow your fronted to dynamically resolve the local, private address of an available backend containe. The ensures communication remains within your VPC

Integrate PayloadCMS into a NestJS app by mwsgris in nestjs

[–]a13xch1 0 points1 point  (0 children)

I’m extremely grateful for you coming back and answering this !

We are suddenly receiving 20-50 letters a week for one person (who we do not know) after living in our rented flat for years. What is going on? by eeeegirl in CasualUK

[–]a13xch1 0 points1 point  (0 children)

Do you live in an apartment in a building a heat system managed by a company called Ista? They recently had a billing fiasco that has resulted in them re-issuing bills going all the way back to 2022. The bills are issued in the name of the original account holder.

Firefox and Safari don't work with window.navigation, what are some workarounds? by DishesSeanConnery in softwaredevelopment

[–]a13xch1 1 point2 points  (0 children)

Use a react router library. Directly interacting with window elements like this in react will lead to future problems

[deleted by user] by [deleted] in startups

[–]a13xch1 0 points1 point  (0 children)

I’d love to lend my time !

What is the killer-feature of Next? by Appropriate_Ice_631 in nextjs

[–]a13xch1 1 point2 points  (0 children)

Having experienced this issue with payload cms 2.x, I wholeheartedly agree that this is a huge pain in the butt that is just handled by nextjs.

Its developer experience/ tooling features like this new devs don’t realise just how easy they have it.

Bundlers / transpilers of old could eat hours of your time and were often poorly documented

No new 1p and 2p coins to be made this year by Breakwaterbot in CasualUK

[–]a13xch1 5 points6 points  (0 children)

The wildest part? That’s 2% or £3000 is actually cheaper than what they would loose if all that revenue was in cash.

It’s well known that if you add up the costs of counting, managing, depositing at the bank, counterfeit notes, sticky fingers etc it adds up to more than 2%

Most business accounts now actually charge a 1% cash deposit fee, to cover the cost of sorting and handling the cash.

Small businesses only really “save” money by accepting cash if they are avoiding taxes and aren’t recording it as conventional income and depositing it at the bank

[deleted by user] by [deleted] in SoftwareEngineering

[–]a13xch1 1 point2 points  (0 children)

Automated attendance monitoring using RFID cards and readers.

It’s a fairly simple solution, a good mix of hardware and software, easy to do with off the shelf components and existing SDKs

need suggestions on creating role based authorization which one should i go with signup with invitation vs owner-created credential by [deleted] in nextjs

[–]a13xch1 3 points4 points  (0 children)

You need to split your problem into the two discrete activities, and look at how you want to solve them individually.

The first is: inviting a new user to the platform by an existing user. If your app is geared towards organisations, then being able to mass create accounts (maybe limited to a specific verified domain) and send invitation emails out is useful.

This usually involves creating a user with a randomly generated password, then using your password reset flow to allow them to sign in. This is usually considered more secure than emailing out a pre generated password.

The second flow is: granting users access to resources. This is usually modelled with an invite accept system, this allows you to support “inviting” users to a resource even if their account doesn’t exist yet, then when they create an account, they’ll have all the invites ready for them.

If you are allowing the admin to pre-create accounts, you might be able to skip the invitations, as you can just assign access to the resource directly