Had a problem in chapter 3.
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 28/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- javascript, react, redux
- Lĩnh vực
- frontend
Hướng nghiên cứu
Bắt đầu với postsSlice.js quanh dòng 88 và tái hiện luồng ở chương 3, trong đó tải các bài đăng và tạo một bài đăng mới. So sánh hành vi của việc nối loadedPosts với việc thay thế state.posts; được xem là hoàn tất khi danh sách được render một lần, các tương tác với emoji hoạt động và các bài đăng mới xuất hiện theo đúng thứ tự dự kiến.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Dave,
Love your stuff! You are the best. Thank you all all you're doing to help us new and inspiring developers.
In chapter three (I believe) I ran into a problem where the code added the 100 posts twice...creating a 200 post rendering and some weird behaviors for clicking on the emojis. When I added a new post it would place the new post right after the first post...not before.
I don't know the reason for this entirely...since I'm still new to the react and redux world but I hung with it for a while and eventually, in the postsSlice.js file (somewhere around line 88), I changed the code from:
'state.posts = state.posts.concat(loadedPosts);'
to
'state.posts = loadedPosts;'
With this change the rendering of all the posts twice stopped. With this change I also noticed that when I created a new post it was placed on the top. So I'm wondering if maybe between when you released the video tutorials and now (a couple of years later) maybe react, reduce, thunk or axios or something else has updated that created this twice rendering and making a 200 entry list of posts problem.
I wanted you to know what I encountered and how it was maybe fixed(???? time will tell as I do more work).
Wishing you all the best.
my email is jdavidmcgee@mac.com if you want to share any further insights...I am a new developer in training and your stuff is really really good!
All the best,
David
- Ngôn ngữ chính
- JavaScript
- Star
- 789
- Fork
- 699
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của gitdagray/react_redux_toolkit
-
Running useEffect in react 18: Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 30/100
gitdagray/react_redux_toolkit#11 · 2 bình luận ·
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 45/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 20/100
gitdagray/react_redux_toolkit#7 · 5 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 55/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 25/100
gitdagray/react_redux_toolkit#3 · 1 bình luận ·
Tất cả issue của gitdagray/react_redux_toolkit
Issue tương tự
-
bug confirmed issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
open-webui/open-webui#30750 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
-
Mend: dependency security vulnerability untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100