Merge branch 'Update_readme' into 'master'

Update README file

See merge request saburly/kitabcitab/kitabcitab-frontend!8
This commit was merged in pull request #8.
This commit is contained in:
Ismail Šošić
2023-03-08 12:33:17 +00:00

View File

@@ -1,36 +1,32 @@
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).
# KitabCitab Web App
## Getting Started
KitabCitab Web App is app that provides books search services by name, author and terms from books.
First, run the development server:
## Functionalities
```bash
npm run dev
# or
yarn dev
```
- Search books
- Read books
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
## App requirements
You can start editing the page by modifying `pages/index.js`. The page auto-updates as you edit the file.
- Node.js
- Next.js
- ElasticSearch server (data)
[API routes](https://nextjs.org/docs/api-routes/introduction) can be accessed on [http://localhost:3000/api/hello](http://localhost:3000/api/hello). This endpoint can be edited in `pages/api/hello.js`.
## Installation
The `pages/api` directory is mapped to `/api/*`. Files in this directory are treated as [API routes](https://nextjs.org/docs/api-routes/introduction) instead of React pages.
1. Clone this project from GitLab repository "https://gitlab.com/saburly/kitabcitab/kitabcitab-frontend.git".
2. In terminal, go to directory of the project and run "npm install" to install all packages.
3. Change ENV_VAR variable inside "envconfig.js" to your server url. Default is "http://localhost:9200".
4. Run "npm run dev" to start app, and then go to url "http://localhost:3000".
This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.
## Example of data object
## Learn More
result = {
"book" : "Hamine pustolovine",
"writer" : "Muhamed Ahmed Mustafa",
"numOfPages": "98",
"text" : "Lorem ipsum"
}
To learn more about Next.js, take a look at the following resources:
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome!
## Deploy on Vercel
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.