Voting App - Feedback?

Nah, 6 hours is when I threw in the towel and went back to passwordless :slight_smile:

1 Like

Hi jer244, I chose Angular because I wanted to learn it and this was a good project to that. I guess you can do without, but I found the 2 way data binding and build in methods extremely helpful here. Basically when I got the data from the database, I can use Angular do all kinds of stuff with it that would normally require to write a lot of javascript code I think.

Maybe anyone used React JS for the front end and can share what the advantages are over Angular?

Yes, I think it makes more sense to only edit your own poll, but thats maybe a personal interpretation.

yeah me too, took me forever! But I was studying every line of code and really tried to understand what it did, same as you.

One tip is maybe, to find a tutorial that explains from A-Z how to build your app, including passport, and then apply it to your own project. Thatā€™s basically what I did. And then Google/Search the missing information you need. Just code, and Google all the bugs, things that are not working. I thought this one was very helpful:

I didnt know what it all meant at first with the Passport JS implementation, but by studying every line of code it gradually all made sense

Because Iā€™m in a feedback mood (and procrastinating working on my own project):

User Experience:
As a user Iā€™m finding it hard to figure out what your charts are trying to show me. I donā€™t really want to have to cross reference a legend to figure it out.

Itā€™s a bit confusing after you leave a vote. Did it work? I get an alert but then I get given the voting options again, am I supposed to vote twice? Would be nice to see some sort of thank you screen and to make it clear what the next step for the user is.

Also needs to report the user if they say anything other than pancakes are awesome. Other answers are not acceptable.

I like that on the my polls page it handles the case where the user has no poll and guides them to create a new one, that is a nice user experience.

It gives very nice validation and clear instant feedback, thatā€™s pretty awesome.

Why is a space a separator? What if I want a two word option? Separators should usually be things that couldnā€™t possibly form part of the data itself.

The validation on the options seems to break with single letter options, for example ā€œAnswera a c cceeā€. This means that the validation flashes red as you are typing. If memory serves correctly you can delay validation in angular, it might be ā€œdebounceā€ in Angular 1.X but donā€™t quote me on that one!

Delete actions should always have some sort of confirmation dialog to protect against accidents.

Going to go and make some breakfast now and consider actually working on my own project. Nice work so far! Angular++

@imtoobose Thanks for the sources!

Looks like Iā€™m going to need to learn something new! Iā€™ve been trying to get this thing started still working with mongo, learning how to authenticate usersā€¦but I havenā€™t gotten nearly that far yet, though, since Iā€™ve been trying to figure out how to do this without paying either mlab or heroku! Heroku makes you pay to run a second dyno, which is required to run mongod. Sandbox mlab accounts donā€™t allow you to create users with the proper admin roles to manage users, and they force the -auth flag to connect, so you canā€™t add an admin yourself either. Iā€™m stumped!

The idea that I will be better off going and learning angular first instead of diving right into this is actually somehow comfortingā€¦Iā€™ve been reluctant to keep pushing through the FCC curriculum since I skipped over the data viz section.

Iā€™m using sandbox mLab just fine.

I have one db user that handles all the POSTs etc to the db. That is sufficient to do everything you need for the backend apps.

You donā€™t need to create a new db user for each new user of your app, if thatā€™s what youā€™re tryingā€¦the db management side of things shouldnā€™t be much different to back end API challenges youā€™ve completed. You might use a few new MongoDB methods, but nothing super fancy is needed.

I also did it without Angular - just EJS for the front end, although admittedly the code stinks and Iā€™m gonna use a front end framework for future projects.

Iā€™m pretty sure you can run mlab with your app. Heroku limits the free hours to roughly a monthā€™s time for all your free dynos, so you should be able to run it. That being said Iā€™d just Hyperdev which, for now, is so much better than Heroku for FCC projects.

Also, you donā€™t really need Angular for this one. I used plain JS and Sass and itā€™s probably easier to manage that than using angular. Jade/Pug takes care of templating very well too.

thanks for the feedback craig! I will look into them to improve my app :slight_smile: Yeah, the space as a separator is a bit weird, it should be commaā€™s I think. Hope your own project is going well now, cheers

yeah, I used the sandbox from mLab for all my projects so far and working fine! Setting up and connecting with mLab and Heroku is actually the easiest part, so donā€™t worry about that. The hardest is the logic in your app :slight_smile:

By the way: read your posts on Medium about passwordless logins, nice one! Will use your article in a new project to try to implement that!

1 Like

Hello Campers! Here is my voting app https://votingking.herokuapp.com . I need someone to thoroughly test it; Iā€™m feeling like Iā€™ve omitted somethings out of want of time and commitments here and there.