|
Building a Car Trader App, 3: Filters based on URL querystring with Formik
We will create 3 dropdown filters based on the URL querystring. When the page loads, we will check if the URL contains any filters in the querystring, if it does we select by default that value in the dropdown. We will use getServerSideProps to load all the makes. Materialui is being used for style. The Make, min price and max price are dropdowns, materialui Select. The next description is a Copypaste from Blog Post + Documentation: When should I use getServerSideProps You should use getServerSideProps only if you need to prerender a page whose data must be fetched at request time. Time to first byte (TTFB) will be slower than getStaticProps because the server must compute the result on every request, and the result cannot be cached by a CDN without extra configuration. . .., BrunoAntunesPT, javascript , ReactJS , NextjsTutorial, Nextjsforbeginners , Reactnextjs, javascriptforbeginners 20200512 b7XLYkqJ5uY
|
|