actuallyreallyalex / gh-jobs Goto Github PK
View Code? Open in Web Editor NEWA tool to help you find your next job.
Home Page: https://www.githubjobs.io/
A tool to help you find your next job.
Home Page: https://www.githubjobs.io/
Given that I make a request and get a response, when I use a
body
in the request, then the data in thebody
should be minimal.
Suggestion: Don't save the whole Job
, just save the id
Given that a job is received from the GitHub Jobs API, when it is added to the database, then it's
created_at
field is renamed tolistingDate
(or similar).
created_at
to listingDate
created_at
to listingDate
Given that I type a direct URL to a page, when the page loads, it should display the proper content.
/signup
should be accessible/login
should be accessible/jobs/202228a1-a793-447d-861d-6c6a38e1cfef
should be accessibleGiven that a user creates a profile, when they access their profile, then they have the ability to select from a list of pre-chosen avatars.
Given that a user attempts to log in, when the email address is not found in the DB, then a message should display that is different than "Invalid credentials."
UserController
Given that a user has 0 saved/hidden jobs, when the user clicks "Show Hidden/Saved Jobs", then the api call to the BE should not be made.
Given that a user views the page, when the page loads, then the server responds with the correct meta data.
Create a profile for a user
UserState
to RootState
setIsLoggedIn()
to UserAction
<Navigation />
component<Header />
and link for LogIn to <Navigation />
Login
Pageemail
fieldpassword
fieldlogin
buttonCreate an account
buttonUser
ControllerLoginState
to RootState
setUserType()
to LoginAction
SignUp
pageLogin
pageSignup
page<FormError />
component<FormError />
to Login
and Signup
Login
PageSignup
PageLogin
link in <Navigation />
Login
Cypress TestSignup
Cypress TestisLoggedIn
is true
, send them back to "Search" but logged inProfile
Pagename
and email
in Profile
pageinitializeApplication()
logicProfile
page<Button />
component<Button />
test
confirmPassword
validation - Create New UserconfirmPassword
validation - Reset PasswordLoginResponse
typeutil.ts
<Button />
secondary style<FormError />
into <Notification />
notificationMessage
and notificationType
are reset on initial load<Notification />
UserController
// TODO
commentsGiven that the design of GitHub Jobs is changing, when the
Button
component is displayed, then it is the new design.
box-shadow
OptionsPanel
SearchInput
ProfileAccountDetails
ProfileAccountStats
Settings
ResetPassword
DeleteProfile
EditProfile
Given that I see a list of jobs on GitHub Jobs, when a request is made, it's coming from the server and the database.
JobsModel
JobsController
TODO
sTODO
sGET /jobs
Given that there are no jobs and a request to
/jobs
is made from the app, when the screen displays, then the LoadingIndicator should be displayed until the response is sent back and results are ready to display to the user.
Given that the
Notification
component usesreact-toastify
, when the Notification appears, then it should contain an icon along with some text.
Given that I'm a developer, and the code is getting large, when I use CSS, then it should be in the component file itself
styled-components
Button
CSSCheckbox
CSSCopyright
CSSHeader
CSSInput
CSSJobCard
CSSLoadingIndicator
CSSNavigation
CSSNotification
CSSOptionsPanel
CSSPagination
CSSPaginationItem
CSSPaginationMore
CSSPaginationNavigation
CSSProfileDelete
CSSProfileDisplay
CSSProfileEdit
CSSProfileReset
CSSProfileSavedJobs
CSSSearchInput
CSSDetails
CSSLogin
CSSSearch
CSSSignup
CSSGiven that a user makes a search, when the BE is hit, then it does not hit the GitHub Jobs API, but makes a DB query.
Taken from #40.
GET /jobs/search
to include DB query (No Location)GET /jobs/search
to include location
Given that a user is on the Search page, when they want to search by jobs that are of type
"Contract"
, then they have a checkbox to do so.
Given that a user uses the
OptionsPanel
, when they make a selection, then they should have the ability to initiate a search from theOptionsPanel
.
OptionsPanel
ButtonOptionsPanel
Need to add back MongoDB support. Look to previous projects for guidance. Also create a cluster on MongoDB Atlas
MONGODB_URL
with cluster urlNeed to send a welcome email when someone joins GH Jobs
UserController
to send email upon successful signup"test"
// TODO
commentsGiven that I'm not on page 1 on
Search
, when I go to view my SavedJobs, then thecurrentPage
should be reset to1
.
currentPage
in thunk
Given that a user opens a job link in a new tab, or accesses the url for a job directly, when the page loads, then it should display the
Details
page correctly (and not the BE response in JSON format).
Details
pageapplicationError.spec.js
details.spec.js
directPageAccess.spec.js
hiddenJobs.spec.js
savedJobs.spec.js
Given that I want to use Cypress for integration testing, when I open it, then it should be
v4.12.1
.
Given that a user is in the application, when an error occurs, then the error boundary is displayed.
https://reactjs.org/docs/error-boundaries.html
error
to ApplicationState
ErrorFallback
Given that I am a GitHub Jobs User, when I view my Profile, then I see the new Profile redesign.
Take inspiration from this example.
Given that a user is viewing the hidden/saved jobs, when 0 results come up (or there are 0 hidden/saved jobs), then the text should read "No results."
Hook up Heroku with domain:
githubjobs.io
githubjobs.io
Given that a user clicks on the job link, when they land on the
Details
page, the client should request information from the server using that job'sid
.
JobController
to handle request for specific jobDetails
when receiving dataChicago Gives Zurich Result - Actually this is just a straight up issue with the GitHub Jobs API. The service isnβt great, in my opinion, aside from just listing all the jobs they have available. For instance, full_time doesnβt work as a search, even if you follow their docs. Same with searches. Itβs not very good. I plan to implement a new version that just takes all the jobs they have, and then any searches are automatically filtered based on my own filter/search logic.
Given that a the Profile page is being viewed, when the content hits the bottom of the screen, then there is a bit of bottom margin.
Given that visual regression doesn't work really (at least the plugin you're currently using), when you run
npm test
, then it shouldn't test using the plugin anymore.
Users should be able to delete their profile if they choose to do so.
isDeletingProfile
to UserState
setIsDeletingProfile()
to UserAction
ProfileReset
ProfileEdit
ProfileDisplay
delete profile
buttonProfileDelete
UserController
to allow for profile deletionGiven that a user saves a job, when the request/response is sent/received, only the
id
field is saved, not the wholeJob
.
id
id
id
savedJobs
for all Users in DBGiven that I am a GH Jobs user and I have already created a GH Jobs account, when I want to save a job and view it later, then I can do so by viewing my Profile.
savedJobs
in UserState
addSavedJob()
in UserAction
removeSavedJob()
in UserAction
localStorage
(don't want user data)<JobCard />
savedJobs
in UserModel
UserControler
to accept a PATCH
to change the user's savedJobs
setSavedJobs()
to UserAction
addSavedJob()
and removeSavedJob()
savedJob
savedJob
<Notification />
to Search
Details
<Notification />
to Details
As an original user, when I access the Heroku url, I should get forwarded to the githubjob.io domain.
308
Redirect in Serverreferrer
req.host
=== gh-jobs.herokuapp.com
|| www.githubjobs.io
req.hostname
Given that a user has some hidden jobs, when a user makes a search, then the hidden jobs should not be returned in the search results.
initializeApplication()
logicJobController
to accept POST
with body
containing userId
id
to UserState
userId
to /jobs/search
JobController
for /jobs/search
/jobs
stub/jobs/search
stubNeed to incorporate
prettier
andeslint
into the build process
npm run build
should both format and lint my code.Given that an error occurs outside of the Home Page (
Details
for example), when the user clicks "Try again", then the url is redirected to/
.
Probably just need to put a
cy.wait()
in there somewhere.
Given that I need to run tests on code, when I run the tests, then Pagination should only fail if something is broken, not because the test itself is broken.
Investigate Issue
Diagnose Isue
Implement Solution
Given that a user is viewing their saved jobs, when they want to return to the profile display page, then they should be able to do so.
Given that the user sees a job they don't care for, when they click a "hide" button, then the job should not appear to them again, unless they go to the "Hidden Jobs" section of their profile and "unhide" it.
JobCard
Details
hiddenJobs
(similar to savedJobs
)HiddenJobs
profile viewEmail should not be from my personal account, but from domain account
Given that I see an alert on GitHub Jobs, when it appears, it should be
react-toastify
.
https://fkhadra.github.io/react-toastify/introduction/
react-toastify
Notification
to use react-toastify
Notification
occurancesNotification
occuranceGiven that a user selects to hide a job, when they click the button, then the job is removed from the current view.
Given that
Modal
is a new component, when it is used, then it should have it's own state in Redux.
ModalState
ModalState
to RootState
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.