Skip to content

Commit 409b76e

Browse files
committed
Add files
1 parent ca48b68 commit 409b76e

40 files changed

+8843
-0
lines changed

Diff for: .eslintrc.json

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"extends": "next/core-web-vitals",
3+
"rules": {
4+
"@next/next/no-img-element": "off",
5+
"react/no-unescaped-entities": "off"
6+
}
7+
}

Diff for: .gitignore

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2+
3+
# dependencies
4+
/node_modules
5+
/.pnp
6+
.pnp.js
7+
.yarn/install-state.gz
8+
9+
# testing
10+
/coverage
11+
12+
# next.js
13+
/.next/
14+
/out/
15+
16+
# production
17+
/build
18+
19+
# misc
20+
.DS_Store
21+
*.pem
22+
23+
# debug
24+
npm-debug.log*
25+
yarn-debug.log*
26+
yarn-error.log*
27+
28+
# local env files
29+
.env*.local
30+
.env
31+
32+
# vercel
33+
.vercel
34+
35+
# typescript
36+
*.tsbuildinfo
37+
next-env.d.ts
38+
39+
# custom
40+
games.json
41+
games_metadata.json
42+
*.bak

Diff for: LICENSE

+674
Large diffs are not rendered by default.

Diff for: README.md

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# Earplug
2+
3+
## Overview
4+
5+
This is a game library website that takes as input a json containing games titles and displays a library of those games using the igdb API.
6+
7+
## Preview
8+
9+
## Installation
10+
11+
```bash
12+
git clone https://github.com/delath/earplug.git
13+
```
14+
15+
```bash
16+
npm install
17+
```
18+
19+
Set up environment variables in `.env`
20+
21+
```
22+
IGDB_CLIENT_ID=<YOUR_IGDB_CLIENT_ID>
23+
IGDB_CLIENT_SECRET=<YOUR_IGDB_CLIENT_SECRET>
24+
```
25+
26+
Create a `games.json` in the root of the repository, containing all the titles of the games to display, as an example:
27+
```json
28+
[
29+
"AI The Somnium Files",
30+
"Alan Wake II",
31+
"Among Us",
32+
"Animal Well"
33+
]
34+
```
35+
36+
Start the website in dev mode
37+
38+
```bash
39+
npm run dev
40+
```
41+
42+
The first time only, it might some time to fetch all the data and write it on the `games.metadata.json`, a file you can manually edit should you want to manage the games on your main page.
43+
44+
## Acknowledgments
45+
46+
Almost all of this project has been based on the work of [mvximenko](https://github.com/mvximenko), you could say this is a fork of [gg](https://github.com/mvximenko/gg) with a different goal.

Diff for: jsconfig.json

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"compilerOptions": {
3+
"paths": {
4+
"@/*": ["./src/*"]
5+
}
6+
}
7+
}

Diff for: next.config.js

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/** @type {import('next').NextConfig} */
2+
const nextConfig = {
3+
webpack(config) {
4+
config.module.rules.push({
5+
test: /\.svg$/i,
6+
issuer: /\.[jt]sx?$/,
7+
use: ['@svgr/webpack'],
8+
});
9+
10+
return config;
11+
},
12+
experimental: {
13+
webpackBuildWorker: true,
14+
},
15+
reactStrictMode: true,
16+
images: {
17+
domains: ['images.igdb.com'],
18+
},
19+
};
20+
21+
module.exports = nextConfig;

0 commit comments

Comments
 (0)