Skip to content

Commit

Permalink
Updating template (#1)
Browse files Browse the repository at this point in the history
* Updating dependencies and fixing next.config.js

* Adding _document to pages

* Adding example basic component

* Added basic OpenGraph properties
  • Loading branch information
Zekel97 committed Oct 19, 2022
1 parent 28a29e8 commit e38ee37
Show file tree
Hide file tree
Showing 9 changed files with 2,103 additions and 24 deletions.
1 change: 1 addition & 0 deletions .env
@@ -0,0 +1 @@
NEXT_PUBLIC_BASE_URL=http://127.0.0.1:3000
6 changes: 6 additions & 0 deletions components/HelloWorld/HelloWorld.module.scss
@@ -0,0 +1,6 @@
.title {
@apply m-0;

@apply font-bold;
@apply text-7xl text-center;
}
11 changes: 11 additions & 0 deletions components/HelloWorld/HelloWorld.tsx
@@ -0,0 +1,11 @@
import styles from './HelloWorld.module.scss';

const HelloWorld = () => {
return (
<h1 className={styles.title}>
Hello world!
</h1>
);
};

export default HelloWorld;
6 changes: 2 additions & 4 deletions next.config.js
Expand Up @@ -2,10 +2,8 @@
const nextConfig = {
reactStrictMode: true,
swcMinify: true,
experimental: {
images: {
unoptimized: true,
},
images: {
unoptimized: true,
},
}

Expand Down
21 changes: 11 additions & 10 deletions package.json
Expand Up @@ -5,24 +5,25 @@
"scripts": {
"dev": "next dev",
"build": "next build",
"export": "yarn && yarn build && yarn next export",
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"next": "12.2.3",
"next": "12.3.1",
"react": "18.2.0",
"react-dom": "18.2.0"
},
"devDependencies": {
"@types/node": "18.6.2",
"@types/react": "18.0.15",
"@types/node": "18.8.5",
"@types/react": "18.0.21",
"@types/react-dom": "18.0.6",
"autoprefixer": "^10.4.8",
"eslint": "8.20.0",
"eslint-config-next": "12.2.3",
"postcss": "^8.4.14",
"sass": "^1.54.0",
"tailwindcss": "^3.1.7",
"typescript": "4.7.4"
"autoprefixer": "^10.4.12",
"eslint": "8.25.0",
"eslint-config-next": "12.3.1",
"postcss": "^8.4.18",
"sass": "^1.55.0",
"tailwindcss": "^3.1.8",
"typescript": "4.8.4"
}
}
14 changes: 14 additions & 0 deletions pages/_document.tsx
@@ -0,0 +1,14 @@
import { Html, Head, Main, NextScript } from 'next/document';

export default function Document() {
return (
<Html lang="en">
<Head />

<body>
<Main />
<NextScript />
</body>
</Html>
);
}
11 changes: 8 additions & 3 deletions pages/index.tsx
@@ -1,5 +1,6 @@
import type { NextPage } from 'next'
import Head from 'next/head'
import HelloWorld from '../components/HelloWorld/HelloWorld'
import styles from '../styles/Home.module.scss'

const Home: NextPage = () => {
Expand All @@ -8,13 +9,17 @@ const Home: NextPage = () => {
<Head>
<title>Create Next App</title>
<meta name="description" content="Generated by create next app" />

<meta property="og:title" content="Next Website"></meta>
<meta property="og:type" content="website"></meta>
<meta property="og:image" content="#"></meta>
<meta property="og:url" content={`${process.env.NEXT_PUBLIC_BASE_URL}/`}></meta>

<link rel="icon" href="/favicon.ico" />
</Head>

<main className={styles.main}>
<h1 className={styles.title}>
Hello world!
</h1>
<HelloWorld />
</main>
</div>
)
Expand Down
7 changes: 0 additions & 7 deletions styles/Home.module.scss
Expand Up @@ -7,10 +7,3 @@
@apply px-16 py-0;
@apply min-h-screen;
}

.title {
@apply m-0;

@apply font-bold;
@apply text-7xl text-center;
}

0 comments on commit e38ee37

Please sign in to comment.