Comments (8)
@TheOdinProject/javascript Can someone take a look please.
from curriculum.
however, for some reason, some people find useEffect kind of difficult
@royalh23 have you noticed any trend in reasoning for this, or has it more been that people express difficulty without reason expanding on what that difficulty is?
Explicitly mentioning that a useEffect needs to be used may be a good idea here regardless. The lesson on effects doesn't exactly go into useEffect with fetching data too in depth from a quick glance (there's a very short sentence or two that quickly mentions "external systems like an API", but beyond that I don't believe there's anything), so it may not be super apparent that's the expectation here.
I am wondering if we should update the effects lesson to go into more detail about other times to use the useEffect hook, but as far as this issue goes adding some verbiage to the project may be good. I'd like to hear your response to my above question first before assigning, though.
from curriculum.
Fetching in react, including with useEffect is gone into much more detail in a later "Fetching Data in React" lesson.
I can't remember the exact reason, but I remember reading that the decision to require a basic fetching in Memory Card before the proper Fetching lesson was intentional. Perhaps because fetching is not anything special and doesn't actually have to be done in an effect in order to work, and the fetching lesson just expands on React-specific stuff.
Perhaps @01zulfi might have more insight into this.
from curriculum.
If it's intentional then maybe this is fine. If we wanted to make a change (not necessarily saying we would have to) we could add a note in this project about covering fetching data in React in more detail later, or update the fetching lesson to call back to this project (You may have done XYZ back in the [Memory Card project](...)
or something).
from curriculum.
I don't exactly remember at the top of my head, but I do think we might've kept on how to fetch in memory card project purposefully vague. I wanted learners to decide on their app's behaviour and built their React components around them. Let's say they want to load data on a user event i.e. button click then they wouldn't need an effect. But if they want to load data on page load, then they'll need an effect. Similarly, will data be fetched on every user selection, or is it a one time thing? I want the learners to come up with their solutions as they see fit. Adding in a "you might need useEffect" will force learners to use effect (lol) even if they could've done without it.
Additionally, the requirement for fetching from external api in memory card project is intentional even if the course doesn't formally guide the learners. I want them to Google/research their way into completing the project, and then come across the fetching data lesson with a understanding of the problem.
from curriculum.
^ That all sounds good to me. Especially for this point in the curriculum (didn't realize exactly where React course was placed at first 😆 ), providing less explicit instruction makes sense to help users figure things out themselves/do things their own way.
from curriculum.
@royalh23 have you noticed any trend in reasoning for this, or has it more been that people express difficulty without reason expanding on what that difficulty is?
@thatblindgeye I've seen some people ask if it's okay not to use effects in the project since they can basically fetch data inside an event handler.
@01zulfi @MaoShizhong I mean if learners don't use effects in the project, how will they get the chance to practice useEffect? They might be using effects in the upcoming projects but Memory Card feels like a sweet spot because it comes right after introducing effects.
from curriculum.
I think I'll defer to @01zulfi first, given he was more directly involved with the React course's intentions and direction. Would greatly value his opinion here.
from curriculum.
Related Issues (20)
- JavaScript Course: Adding note about template literals on import statements HOT 3
- Ruby On Rails: Problem in Knowledge Check of Routing Lesson. Postman Chrome extension is deprecated HOT 5
- Javascript Course: Constructors Are Bad For JavaScript should be removed from assignments HOT 2
- nodeJS: More Detailed Explanation in 'Routes and Controllers' Lesson HOT 1
- nodeJS/authentication: missing an important middleware function , app.use(passport.initialize())
- The Asset Pipeline: <learning overview item with no reference in lesson> HOT 1
- Techniques: <most of the external links refuses to load> HOT 3
- Testing Basics: Broken link: "Read about the basic process and the benefits of TDD." HOT 1
- Command Line Basics: Remove Assignment & Additional Resource Items HOT 4
- Intermediate HTML and CSS Course: Link to previous lesson is under the Ruby path instead of Javascript path HOT 1
- Installing Node.js: <Short description of your suggestion> HOT 3
- Links and Images: broken link HOT 2
- Positioning : Adding Beginner-Friendly CSS Positioning Videos HOT 4
- Possible copyright violation in Introduction to Git: <Short description of your suggestion> HOT 3
- Rock Paper Scissors: <Third bullet point in the "Setup the project structure" step should be formulated differently> HOT 1
- React: Sandbox links don't work in the second assignment HOT 4
- CSS Units: <Short description of your suggestion> HOT 1
- Ruby On Rails: Capitalization / Formatting issue in Members Only project HOT 3
- getting_hired: fix typo HOT 5
- Ruby On Rails: Leftover Asterisk (*) from the last Pull Request in Members Only HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from curriculum.