This project was generated with Angular CLI version 1.1.3.
To run this app
npm install
npm start
Go to localhost:3000 to view the app
For the retain previous scroll position, you can change the delayed time in
/node_modules/delayed-scroll-restoration-polyfill/index.js
change the value of var SCROLL_RESTORATION_TIMEOUT_MS
The following required functionality is completed:
- Able to load and display the deals returned from api: GET https://tuangou.grubmarket.com/api/deals
- Clicking on one of the deals should navigate to the deal details page.
- Should display the details by using content returned from "GET https://tuangou.grubmarket.com/api/deals/{dealId} API"
- Should remember scroll position in deals page so that we coming back from the details page, it's positioned at the deal user last viewed.
- For deals sold by GrubMarket (the ones with "GM" icon and labeled “官方团购" at the top of the details page) such as "https://tuangou.grubmarket.com/#/deals/49d20b44-0cdc-4a2d-9d80-b8281d0a993c".
- Each product in the deal has a category classification. Design a filter in details page to filter products by category
The following optional features are implemented:
- Implemented infinite loading on deals
- Added spinner when fetching data
- Navigation Bar, containing Logo, "主页", "热帖", "团购", "注册" and "登入"
- Filters to filter Official deals, or/and Active deals.
- Animation when hover on the deal
- Include view counts, likes counts, orders counts in deal
- Sticky "结算" button on the deal-detail view
- Able to hide and show more pickup locations
- Added order history of deal
- Implemented infinite loading on order history
The following Bonus features are implemented:
- improve performance by reducing payload size, only load resources (e.g. images) when in viewing area, use cached content.
Copyright [2017] [Jiapei Liang]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.