Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial Template Setup #2

Merged
merged 7 commits into from
Jan 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"env": {
"browser": true,
"es6": true,
"node": true
},
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:prettier/recommended",
"prettier/@typescript-eslint"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 2018,
"sourceType": "module"
},
"plugins": [
"react",
"@typescript-eslint"
],
"rules": {
},
"settings": {
"react": {
"version": "detect"
}
}
}
6 changes: 6 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module.exports = {
semi: false,
singleQuote: true,
parser: 'typescript',
trailingComma: 'none',
};
25 changes: 24 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
# c0d3.com

Repo for c0d3.com. A website to train people to be full stack software engineers.
Repo for c0d3.com powered by NextJS. A website to train people to be full stack software engineers.

## Prerequisites

- Node.JS
- Git

## How to Start

1. Clone the repository with SSH or HTTPS
> SSH - `git clone [email protected]:garageScript/c0d3.com.git`

> HTTPS - `git clone https://github.com/garageScript/c0d3.com.git`
2. After cloning the repository, run `npm install`.
3. Start the local development server with `npm run dev`.
4. Navigate to `http://localhost:3000` to view your application.

## Contributing

Watch the video below to find out how to develop with TypeScript in React

[![React TypeScript Tutorial](http://i3.ytimg.com/vi/Z5iWr6Srsj8/hqdefault.jpg)](https://www.youtube.com/watch?v=Z5iWr6Srsj8)

Before submitting your code run `npm run autofix`.
Empty file added components/.gitkeep
Empty file.
2 changes: 2 additions & 0 deletions next-env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/// <reference types="next" />
/// <reference types="next/types/global" />
32 changes: 32 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"name": "with-typescript",
"version": "1.0.0",
"scripts": {
"dev": "next",
"build": "next build",
"start": "next start",
"lint": "eslint . --ext .ts --ext .tsx",
"autofix": "eslint . --ext .ts --ext .tsx --fix",
"type-check": "tsc"
},
"dependencies": {
"isomorphic-unfetch": "3.0.0",
"next": "latest",
"react": "^16.12.0",
"react-dom": "^16.12.0"
},
"devDependencies": {
"@types/node": "^12.12.21",
"@types/react": "^16.9.16",
"@types/react-dom": "^16.9.4",
"@typescript-eslint/eslint-plugin": "^2.17.0",
"@typescript-eslint/parser": "^2.17.0",
"eslint": "^6.8.0",
"eslint-config-prettier": "^6.9.0",
"eslint-plugin-prettier": "^3.1.2",
"eslint-plugin-react": "^7.18.0",
"prettier": "^1.19.1",
"typescript": "3.7.3"
},
"license": "ISC"
}
7 changes: 7 additions & 0 deletions pages/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import * as React from 'react'

const IndexPage: React.FC = () => {
return <h1>c0d3.com under construction</h1>
}

export default IndexPage
7 changes: 7 additions & 0 deletions pages/login.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import * as React from 'react'

const Login: React.FC = () => {
return <h1>Login</h1>
}

export default Login
7 changes: 7 additions & 0 deletions pages/register.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import * as React from 'react'

const Register: React.FC = () => {
return <h1>Register</h1>
}

export default Register
23 changes: 23 additions & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"compilerOptions": {
"allowJs": true,
"alwaysStrict": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"isolatedModules": true,
"jsx": "preserve",
"lib": ["dom", "es2017"],
"module": "esnext",
"moduleResolution": "node",
"noEmit": true,
"noFallthroughCasesInSwitch": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"resolveJsonModule": true,
"skipLibCheck": false,
"strict": true,
"target": "esnext"
},
"exclude": ["node_modules"],
"include": ["**/*.ts", "**/*.tsx"]
}
Loading