Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minju: Component Based Design, 3 Weeks #419

Open
5 of 12 tasks
minjupgeorge opened this issue Oct 5, 2022 · 4 comments
Open
5 of 12 tasks

Minju: Component Based Design, 3 Weeks #419

minjupgeorge opened this issue Oct 5, 2022 · 4 comments

Comments

@minjupgeorge
Copy link
Contributor

minjupgeorge commented Oct 5, 2022

Learning Objectives

Priorities: 🥚, 🐣, 🐥, 🐔 (click to learn more)

There is a lot to learn in this repository. If you can't master all the material
at once, that's expected! Anything you don't master now will always be waiting
for you to review when you need it. These 4 emoji's will help you prioritize
your study time and to measure your progress:

  • 🥚: Understanding this material is required, it covers the base skills you'll
    need for this module and the next. You do not need to finish all of them but
    should feel comfortable that you could with enough time.
  • 🐣: You have started all of these exercises and feel you could complete them
    all if you just had more time. It may not be easy for you but with effort you
    can make it through.
  • 🐥: You have studied the examples and started some exercises if you had time.
    You should have a big-picture understanding of these concepts/skills, but may
    not be confident completing the exercises.
  • 🐔: These concepts or skills are not necessary but are related to this module.
    If you are finished with 🥚, 🐣 and 🐥 you can use the 🐔 exercises to push
    yourself without getting distracted from the module's main objectives.

1. Rendering Static Pages

  • recreate an HTML/CSS web page using pure functions components and encapsulated styles

🥚 JSX : you can ...

  • Write elements with JSX syntax

2. Rendering Data

  • functional React components
  • render a static page with provided data
  • component props
  • splitting components with design in mind

🥚functional React components: you can ...

  • Create a React function component (both function definition and arrow function styles)

  • Import/export components between files

🥚 Render data: you can

  • Use interpolation ({}) to insert JavaScript expressions into JSX
  • Render a list using the .map method

🥚 Components and props : you can ...

  • create small, reusable components
  • how to pass props into React components

🥚 Create reusable components: you can ...

  • Nest components within other components
    • one folder with a main component
    • sub-components for your convenience (not part of public contract)

3. Stateful Components

  • VDOM
  • what is a hook
  • useState
  • useEffect (any side-effect)
  • component lifecycle

🥚VDOM : you ....

  • can differenciate the real dom from the virtual dom
  • know what reconciliation process is ..

🥚 Hook

  • simple, just enough for the flavor
  • the react docs "rules of hooks"

🥚 use-state

🥚 use-effect

🥚 component lifecycle

4. Events

  • create components that manage internal state and emit custom events
  • handling events
  • build reusable components that take functions as arguments
  • child components communicating with parent components
  • passing functions as props

5. Component Structure

  • splitting components with logic in mind
    • why create dumb components when hooks can be anywhere?
  • re-render cycles (all children)
    • why putting state at lower levels is efficient
    • why not to use everything in global state

6. Consuming APIs

  • fetch and use API data in components
  • async useEffect callbacks

7. Frontend Routing

  • react router

8. Global State

  • being careful about what you put in useContext
    • only move data to context when it's necessary
  • store and manage global app state shared between components
  • useContext
    • shared state, not the same as useState
  • other state management systems/strategies exist
@minjupgeorge
Copy link
Contributor Author

minjupgeorge commented Oct 5, 2022

Week 1

Sorry @danielhalasz for late check-in.

I Need Help With:

Last week I was trying to understand React from documents as well as YouTube videos. Sometimes video search itself will eat my time. Finally I got one in my native language and boost up my interest towards React.video. So I missed the check-in in middle.

I was confused with props in the beginning but now it is clear.

What went well?

  • I was able to display movies using map in React.
  • I understood what is a component and how to use it .
  • I tried to display a form by referring the video which I have mentioned earlier.

What went less well?

  • Most of the react videos were using 'Use state' ,which I felt difficult to understand.
  • Sometimes html tag and react tag got confused.

Lessons Learned

  • How React is working with components.
  • Data flow between APP.js , Component.JSX and html files.
  • I understood map and used it to display a list of items

Sunday Prep Work

-Practice Practice...

@danielhalasz
Copy link
Contributor

  • Most of the react videos were using 'Use state' ,which I felt difficult to understand.
  • Sometimes html tag and react tag got confused.

you can write me on Slack if you have specific questions. is state a bit clear now after the Sunday class?

@minjupgeorge
Copy link
Contributor Author

minjupgeorge commented Oct 5, 2022

@danielhalasz

Yes Daniel, it is clear. now am working with Todolist.
image

@minjupgeorge
Copy link
Contributor Author

minjupgeorge commented Oct 7, 2022

Week 2

I have push my Todolist code here
ScreenShots
image

I Need Help With:

  1. Where I have to put Javascript validations ? I tried to print alert message in components . but it is not working.

What went well?

  • I was able to create add item, delete item in Todolist project
  • I understood clearly usage of hooks after several practice especially I had confusion in setting value with set function

What went less well?

I felt difficult to put css with in the component. then I add my styles to index.css .

Lessons Learned

  • How React is working with components, hooks.
  • Able to understand 'UseState'

Sunday Prep Work

-Practice Practice...

  • Trying to display the alert message
  • Need to add 'edit task' message to my Todolist

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants