-
Notifications
You must be signed in to change notification settings - Fork 898
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1159 from sreyas-b-anand/codespace-moonlit-goblin…
…-q7qj7xjg94wp2xvqr Grammr/sreyas
- Loading branch information
Showing
22 changed files
with
6,431 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"extends": ["next/babel","next/core-web-vitals"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. | ||
|
||
# dependencies | ||
/node_modules | ||
/.pnp | ||
.pnp.js | ||
.yarn/install-state.gz | ||
|
||
# testing | ||
/coverage | ||
|
||
# next.js | ||
/.next/ | ||
/out/ | ||
|
||
# production | ||
/build | ||
|
||
# misc | ||
.DS_Store | ||
*.pem | ||
|
||
# debug | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
|
||
# local env files | ||
.env*.local | ||
|
||
# vercel | ||
.vercel | ||
|
||
# typescript | ||
*.tsbuildinfo | ||
next-env.d.ts | ||
|
||
|
||
*.env | ||
.vercel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
# Grammr | ||
|
||
## Project Overview | ||
**Grammr** is a web application built with **Next.js**, **JavaScript**, **Tailwind CSS**, and **Material-UI (MUI)** and **Gemini Api**. | ||
|
||
## Table of Contents | ||
1. [Installation](#installation) | ||
2. [Usage](#usage) | ||
3. [Tech Stack](#tech-stack) | ||
4. [Features](#features) | ||
5. [Contributing](#contributing) | ||
6. [License](#license) | ||
|
||
## Screenshots | ||
|
||
Here’s a preview of the Grammr interface: | ||
|
||
![Grammr App Screenshot](./assets/grammr.png) | ||
## Installation | ||
To set up the Grammr Checking App, follow these steps: | ||
|
||
1. **Clone the Repository** | ||
```bash | ||
git clone https://github.com/sreyas-b-anand/grammr.git | ||
cd grammr | ||
2. **Install Dependencies** | ||
- Ensure you have Node.js installed, then run: | ||
```bash | ||
npm install | ||
3. **Run the Application** | ||
Start the development server: | ||
```bash | ||
npm run dev | ||
|
||
## API Integration | ||
|
||
To utilize the Gemini API, you'll need to follow these steps to set up your API key: | ||
1. **Obtain Your API Key** | ||
- Sign up at [Google AI Studio](https://ai.google.dev/api) to obtain your API key. | ||
2. **Set Up Your API Key** | ||
- Create a `.env.local` file in the root of your project directory if you haven't already. | ||
- Add your API key to the `.env.local` file: | ||
```plaintext | ||
NEXT_PUBLIC_API_KEY=your_api_key_here | ||
``` | ||
|
||
3. **Install the Gemini API SDK** | ||
- If you haven't installed it yet, add the Google AI JavaScript SDK to your project: | ||
```bash | ||
npm install @google/generative-ai | ||
``` | ||
4. **Import the Library and Configure Your Key** | ||
- In your application code, import the library and configure it with your API key: | ||
```javascript | ||
import { GenerativeAI } from '@google/generative-ai'; | ||
const aiClient = new GenerativeAI({ | ||
apiKey: process.env.NEXT_PUBLIC_API_KEY, | ||
}); | ||
``` | ||
5. **Make Your First Request** | ||
- Use the `generateContent` method to generate text: | ||
```javascript | ||
const response = await aiClient.generateContent({ | ||
prompt: "Your prompt here", | ||
// Other parameters as needed | ||
}); | ||
console.log(response); | ||
``` | ||
6. **Restart Your Development Server** | ||
- After setting up your API key and making changes, restart your development server: | ||
```bash | ||
npm run dev | ||
``` | ||
Make sure to keep your `.env.local` file secure and do not share it publicly. | ||
- Access the app in your web browser at http://localhost:3000. | ||
## Tech Stack | ||
- Next.js: A React framework for server-side rendering and static site generation. | ||
- JavaScript: The programming language used for building interactive features. | ||
- Tailwind CSS: A utility-first CSS framework for rapid UI development. | ||
- Material-UI (MUI): A React UI framework that implements Material Design principles. | ||
## Features | ||
- Real-time Grammar Correction: Utilizes Gramformer to provide immediate feedback on grammar errors. | ||
- Responsive Design: Built with Tailwind CSS for a mobile-friendly experience. | ||
- Customizable Components: Leverages MUI for pre-designed, accessible UI components. | ||
- Open Source: The application is open for contributions and improvements. | ||
## Contributing | ||
- Contributions are welcome! Please follow these steps: | ||
## License | ||
- This project is licensed under the MIT License - see the LICENSE file for details. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"compilerOptions": { | ||
"paths": { | ||
"@/*": ["./src/*"] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/** @type {import('next').NextConfig} */ | ||
const nextConfig = {}; | ||
|
||
export default nextConfig; |
Oops, something went wrong.