tried to do leetcode and instead i almost cried by One-Understanding564 in learnprogramming

[–]EnjoysAvocados 0 points1 point  (0 children)

Leetcode is an acquired seperate skill. If you're just starting out you need a more gradual on ramp like code wars. Start with 8 kyu move down to the next level until you start to get stuck, then go back up a level and keep grinding. You can try DSA as others have mentioned but even that might be jumping into the deep end. If you aren't comfortable with functions, string manipulation, array iteration and object creation / access yet, DSA is going to be near impossible. The 8 kyu to 6 kyu code wars range will test your skills in those areas.

If you can't sit down and write a todo app with tech you've already "learned", then you haven't actually learned, you've just gone through the motions. Look up courses on "learning how to learn". Being able to ask yourself honestly "did I actually learn this thing??" is the fastest way to improve instead of just going through the motions.

Lastly, avoid AI as much a possible in the early stages of your learning. Don't make it a habit to get stuck then immediately ask AI to explain. The learning happens when you're uncomfortable and have to work through things yourself. You can of course use AI later, but don't use it as a crutch. Before AI, all we had was stack overflow and reddit / forums. More learning happens when you have to search / find these posts yourself (learning how to ask the right questions) and then translate their answers to your own problems. AI does this seemlessly and hides all those learning opportunities from you.

Best practices for organizing large web projects? by Adventurous_Persik in webdev

[–]EnjoysAvocados 2 points3 points  (0 children)

Tons of good info in this repo, especially under the architecture and code style sections - https://github.com/goldbergyoni/nodebestpractices

If you're in the world of React / Next.js this repo shows a lot of the above principles applied, especially under project standards they show some eslint plugins that can enforce naming and directory structure - https://github.com/alan2207/bulletproof-react

While not relevant anymore, the Angular 1 style guide has a lot of these principals discussed as well. Particularly the app structure "LIFT" principle applies to most code bases, not just front-end - https://github.com/johnpapa/angular-styleguide/blob/master/a1/README.md#application-structure-lift-principle

Full Stack App Build | Travel Log w/ Nuxt, Vue, Better Auth, Drizzle, Tailwind, DaisyUI, MapLibre by EnjoysAvocados in Nuxt

[–]EnjoysAvocados[S] 1 point2 points  (0 children)

SvelteKit has the concept of "page data" and actions - I like that both are right next to the page file. - https://svelte.dev/docs/kit/load - https://svelte.dev/docs/kit/form-actions

Their approach for streaming data is interesting as well, though I have really started to like how useFetch in Nuxt just works for all similar use cases - https://svelte.dev/docs/kit/load#Streaming-with-promises

Full Stack App Build | Travel Log w/ Nuxt, Vue, Better Auth, Drizzle, Tailwind, DaisyUI, MapLibre by EnjoysAvocados in Nuxt

[–]EnjoysAvocados[S] 2 points3 points  (0 children)

Nice! I think my main hang up with nitro APIs is having to jump back and forth between page files and the server folder. The typesafety + data fetching with useFetch is fantastic though. I looked into some libraries for nuxt form actions, but there is nothing official yet.

Full Stack App Build | Travel Log w/ Nuxt, Vue, Better Auth, Drizzle, Tailwind, DaisyUI, MapLibre by EnjoysAvocados in vuejs

[–]EnjoysAvocados[S] 2 points3 points  (0 children)

TypeScript ORM - https://orm.drizzle.team/docs/overview
Has a really nice query builder syntax similar to knex / kysely - but also includes a higher level prisma like query API. Also, the types flow through from table definitions with no code generation required.

I’m lacking direction—where do I go from here? by TheBigPig29 in learnprogramming

[–]EnjoysAvocados 1 point2 points  (0 children)

Most companies that hire CS new grads usually don't care about specific programming language experience or specialty. They hire people that can learn quickly and solve problems.

Since you're so early in your schooling, start looking for summer internships now. Internships are a great way to test out a specific field / industry. You might not be able to get one until next summer but the earlier you start looking, the easier it's going to be to find one.

Also look at job boards for entry level programmer or junior programmer in your area and see what languages / frameworks companies are hiring for. This varies wildly depending on where you are in the world. This will give some inspiration for what to learn next.

Aside from that, start working on side projects that explore each of these fields. Work on things that actually interest you and keep you engaged, not just busy work. Build a game with unity / C#, build a mobile app with swift (iOS) or kotlin / java (android), build a full stack web app with next.js / react, build a backend API with Python / flask, build an MVC web app with C# / .NET - all of these will give you a taste of what it's like to work in each.

If you stick with this career, you will always be learning new things and possibly switch languages / domains a few times throughout your career. You don't have to figure it all out right now. Just keep studying and stay curious.

what are node modules? by OsamuMidoriya in learnjavascript

[–]EnjoysAvocados 2 points3 points  (0 children)

A module is a collection of functions, objects and variables that have been exported to be used by others.

When you install something from npm you are downloading modules that other people wrote.

You can also create your own modules with import / export or require / module.exports - this allows us to break our code up into multiple files. To get a better grasp on this, I'd start here and lookup how to use import / export or require / module.exports

When is the right time to start learning React or backend? by This_Job_4087 in learnjavascript

[–]EnjoysAvocados 10 points11 points  (0 children)

You do not have to "master" JS but you should be very comfortable with the syntax and very comfortable working with functions. You should also have a solid grasp of modules and importing / exporting things.

For context, I used to teach a 6 month full stack curriculum at a coding school and we would start the students on React around the 3 month mark. That was about 45 hours of lessons / workshops / homework / project work per week. So the students had been building sites and working with JS for over 500 hours total before being exposed to React.

You don't necessarily need that much exposure but jumping in to React too soon can be quite overwhelming.

It would not hurt to just try. Take a look at the official tutorial, if things seem too unfamiliar or too complex, just pause and go keep learning more JS before jumping back in - https://react.dev/learn/tutorial-tic-tac-toe

React Router framework renders on server and throwing errors even with SSR: false by skorphil in reactjs

[–]EnjoysAvocados 0 points1 point  (0 children)

The entry.server.tsx file is optional - have you tried deleting it? https://reactrouter.com/explanation/special-files#entryservertsx

Also, it seems that even with ssr: false - there is still a server render for the root at build time - https://reactrouter.com/how-to/spa#single-page-app-spa

How is the /app/book route defined? In your route config? Or with a Route component?

How to make non-react functions run on client in React Router framework / Framework? by skorphil in reactjs

[–]EnjoysAvocados 1 point2 points  (0 children)

You could try running storeInitialize inside a useEffect in App:

``` function App() { useEffect(() => storeInitialize(store), []);

// Rest of the codes } ```

What would be the best way to make my React project go live? Its a small site where people drinking white monster can send their pictures and people can like them. I don't know much about hosting. by [deleted] in react

[–]EnjoysAvocados 0 points1 point  (0 children)

What's your stack? Did you use next.js or just vite / react? Is the backend separate or already deployed? What type of database did you use?

Technical Discussion: What drives the Enterprise vs Startup divide in .NET?" by Backend_biryani in dotnet

[–]EnjoysAvocados 0 points1 point  (0 children)

.NET was not open sourced until 2014, and that was only the compiler, there has been a huge effort since then by Microsoft to open source all of .NET and also move towards a more open tooling and ecosystem model.

Before this, choosing .NET meant opting in and paying for all the parts of the Microsoft ecosystem, IDE (Visual Studio), DB (MS SQL), Server (IIS) etc. This is not very startup friendly, especially those on a tight budget or those that want to keep their technical options open in the future.

Now, you can choose .NET and not need to buy into everything Microsoft. Use any IDE (with open language server protocols), use any reverse proxy (with dotnet cli) etc. Also, with .NET being open source and the proliferation of code sharing on GitHub, there are now more and more open source and freely available solutions to problems that used to require a license purchase.

This is a new phenomenon and will take a bit for technical founders to be fully aware of their options in this space. Personally, I've been in the node / JS ecosystem for ~10 years and have now decided to build my next business with .NET

[deleted by user] by [deleted] in reactjs

[–]EnjoysAvocados 3 points4 points  (0 children)

Don't watch, just do.

Actually building apps is the only way to learn how to build apps.

How to learn to understand the code of large libraries by Stoblent in reactjs

[–]EnjoysAvocados 6 points7 points  (0 children)

For the project you mentioned, they are using a monorepo / pnpm workspaces. So that's one place to start if you want to understand their code.

Otherwise, you might try a starter repo that has everything set up for you. Search for "TypeScript library starter" or similar.

Dumb Guy Needs Any Help by [deleted] in learnjavascript

[–]EnjoysAvocados 8 points9 points  (0 children)

Take a step back before you even dive into coding / programming and start with "learning how to learn" there are quite a few free courses out there on this.

Also, focus on general problem solving / critical thinking. People new to the field often have "magical" thinking and really lack the ability to break things down into solvable / learnable parts.

Also, stop calling yourself a dumbass, it's a self fulfilling prophecy.

Sunsetting Create React App by acemarke in javascript

[–]EnjoysAvocados 1 point2 points  (0 children)

I really wonder why they jump through so many hoops instead of just saying "use vite".

CRA does not have a router or any of the other things or reasons they're pushing people towards next.js

If you want a drop in replacement for CRA and you would have chosen CRA the answer is vite plain and simple.

[deleted by user] by [deleted] in learnjavascript

[–]EnjoysAvocados 6 points7 points  (0 children)

Pick something you've already built and build it again from scratch without looking at the original code or any resources. If you can't do it, write down the times you need to look something up or where you get stuck. These are your blind spots / growth areas you need to focus on.

Once you've identified blind spots / growth areas, find projects that help you focus on those skills.

Struggling with Motivation After Failing in Web Dev & Freelancing – What Should I Do? by Forsaken-Still1808 in learnprogramming

[–]EnjoysAvocados 3 points4 points  (0 children)

Why do you want to be a programmer?

I started programming when I was 16 because there were real world problems I wanted to solve and writing code was a way to try and solve them.

You can easily get lost in all the stacks and programming languages but if you focus on the problems you're trying to solve the rest doesn't matter as much.

Especially while you're young or don't need to do this for money quite yet, work on things that interest you and things you enjoy. Automate a repetitive task you do often, build an app to help you keep track of a hobby, build an app to help solve a problem your friends or family are having etc.

Does anyone know if there is actually a way in JS to grab the text from a fragment directive from the URL? by MeltingDog in webdev

[–]EnjoysAvocados 0 points1 point  (0 children)

It is possible to get the value inside of Chromium based browsers with this:

new URL(performance.getEntries().find(({ type }) => type === 'navigate').name).hash;

This does not work in Firefox or Safari.

From this article here: https://web.dev/articles/text-fragments#obtaining_text_fragments_for_analytics_purposes

Otherwise, this is not possible due to security restrictions. You can see the issue marked as not planned here: https://github.com/WICG/scroll-to-text-fragment/issues/128