These are chat archives for FreeCodeCamp/HelpJavaScript

18th
Nov 2018
Richa
@richa-coder
Nov 18 2018 01:46
Guys, could someone please help me on how to re render a part of component in react? I have 50 buttons and based on the click on butto
Buttons* I have to update the selection on an image which contains 30 buttons...how do I update just the selected button on image..I can't create different components for each button on image...how do I do that? Can I re render just that selected button on image?
Aditya
@ezioda004
Nov 18 2018 04:45
@cmccormack I think I found my problems solution from this PR: freeCodeCamp/freeCodeCamp#30982
Adel
@AdelMahjoub
Nov 18 2018 07:23
@richa-coder that's one of the problems in the conway game of life challenge using react, but it seems unavailable in the new fcc curriculum
@richa-coder check this https://mackville.net/react/gameoflife/index.html, each cell is a div, and only some cells are updating in each cycle, through a set of rules, same problem with what you need except for the rules that are replaced by user clicks
Adel
@AdelMahjoub
Nov 18 2018 07:31
my react engine is not working properly at the moment, always being hijacked by an event bus à la vuejs, like if it were vuetify react components, but yeah the number of buttons dosn't matter, some react ninjas will show up and help if you are still stuck
Richa
@richa-coder
Nov 18 2018 08:49
@AdelMahjoub ,any leads on how have u achieved it? Source code on git?
Richa
@richa-coder
Nov 18 2018 09:45
Also, is it possible to log the name of the component that updated the store?
Christopher McCormack
@cmccormack
Nov 18 2018 13:16
@ezioda004 so you had an extra commit in master and wanted to reset back up upstream master? Was rebasing just moving your commit to the top, was that the problem?
Kelechi Chinaka
@ke1echi
Nov 18 2018 13:38
i feel terrible with design, having a hard time making a landing page
Aditya
@ezioda004
Nov 18 2018 14:18
@cmccormack I didnt try rebasing AFAIK rebasing applies all the commit from 1 branch to another branchs tip so that commit in the master would still exist
Adel
@AdelMahjoub
Nov 18 2018 15:54
@richa-coder the react example I have is using canvas, that one is from @cmccormack, a lot of users here have that challenge complete using react, try search their repos maybe it helps
@richa-coder you also can hide and show using css
Tom
@moT01
Nov 18 2018 16:17
@AdelMahjoub
Adel
@AdelMahjoub
Nov 18 2018 16:19
@moT01 hey, been a while
Tom
@moT01
Nov 18 2018 16:19
yes, welcome back
been on vacation?
Adel
@AdelMahjoub
Nov 18 2018 16:20
kinda of :laughing:
how are you doing
Tom
@moT01
Nov 18 2018 16:21
im good
how are you
im still lingering around the chat rooms
Adel
@AdelMahjoub
Nov 18 2018 16:22
nice, good too thanks
Tom
@moT01
Nov 18 2018 16:22
the increasingly less active chat rooms
Adel
@AdelMahjoub
Nov 18 2018 16:22
yeah, I noticed that too
Tom
@moT01
Nov 18 2018 16:24
writing any code lately?
Adel
@AdelMahjoub
Nov 18 2018 16:25
mostly refreshing some stuff
but I have some projects in mind
And I'll stick away from game development for a while too
Tom
@moT01
Nov 18 2018 16:30
why
games are fun
Adel
@AdelMahjoub
Nov 18 2018 16:34
Yeah, when learning new stuff, game engines, languages, trying various concept / designs and making 'simple' games, it is fun, but any serious game development will require an enormous amount of work and time
gamejams are fun too
And skillsets proficiency is not easy to keep / maintain
Adel
@AdelMahjoub
Nov 18 2018 16:41
I'm trying to connect to irc #express at freenode, but with no success
well it seems no longer available
Nerando Johnson
@Nerajno
Nov 18 2018 22:44
greetings
need a bit help
Nerando Johnson
@Nerajno
Nov 18 2018 22:51
if(typeof questionOne === 'string'){
        score = score + 1;
    }
    if(questionTwo === 'number'){
        score = score + 1;
    }
   console.log(score);
how do i get the score to increase value in questionTwo
Lucci Paula
@luccipaula
Nov 18 2018 23:10
@Nerajno I think you just forgot to add typeof again in the second condition