diff --git a/.gitignore b/.gitignore index 4d29575..3c3629e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,23 +1 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. - -# dependencies -/node_modules -/.pnp -.pnp.js - -# testing -/coverage - -# production -/build - -# misc -.DS_Store -.env.local -.env.development.local -.env.test.local -.env.production.local - -npm-debug.log* -yarn-debug.log* -yarn-error.log* +node_modules diff --git a/client/.gitignore b/client/.gitignore new file mode 100644 index 0000000..4d29575 --- /dev/null +++ b/client/.gitignore @@ -0,0 +1,23 @@ +# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. + +# dependencies +/node_modules +/.pnp +.pnp.js + +# testing +/coverage + +# production +/build + +# misc +.DS_Store +.env.local +.env.development.local +.env.test.local +.env.production.local + +npm-debug.log* +yarn-debug.log* +yarn-error.log* diff --git a/package-lock.json b/client/package-lock.json similarity index 99% rename from package-lock.json rename to client/package-lock.json index 55b52be..a8f47d0 100644 --- a/package-lock.json +++ b/client/package-lock.json @@ -13,6 +13,7 @@ "@testing-library/user-event": "^13.5.0", "react": "^18.0.0", "react-dom": "^18.0.0", + "react-router-dom": "^6.2.2", "react-scripts": "5.0.0", "web-vitals": "^2.1.4" } @@ -7965,6 +7966,14 @@ "he": "bin/he" } }, + "node_modules/history": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/history/-/history-5.3.0.tgz", + "integrity": "sha512-ZqaKwjjrAYUYfLG+htGaIIZ4nioX2L70ZUMIFysS3xvBsSG4x/n1V6TXV3N8ZYNuFGlDirFg32T7B6WOUPDYcQ==", + "dependencies": { + "@babel/runtime": "^7.7.6" + } + }, "node_modules/hoopy": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/hoopy/-/hoopy-0.1.4.tgz", @@ -13243,6 +13252,30 @@ "node": ">=0.10.0" } }, + "node_modules/react-router": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.2.2.tgz", + "integrity": "sha512-/MbxyLzd7Q7amp4gDOGaYvXwhEojkJD5BtExkuKmj39VEE0m3l/zipf6h2WIB2jyAO0lI6NGETh4RDcktRm4AQ==", + "dependencies": { + "history": "^5.2.0" + }, + "peerDependencies": { + "react": ">=16.8" + } + }, + "node_modules/react-router-dom": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.2.2.tgz", + "integrity": "sha512-AtYEsAST7bDD4dLSQHDnk/qxWLJdad5t1HFa1qJyUrCeGgEuCSw0VB/27ARbF9Fi/W5598ujvJOm3ujUCVzuYQ==", + "dependencies": { + "history": "^5.2.0", + "react-router": "6.2.2" + }, + "peerDependencies": { + "react": ">=16.8", + "react-dom": ">=16.8" + } + }, "node_modules/react-scripts": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/react-scripts/-/react-scripts-5.0.0.tgz", @@ -21781,6 +21814,14 @@ "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" }, + "history": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/history/-/history-5.3.0.tgz", + "integrity": "sha512-ZqaKwjjrAYUYfLG+htGaIIZ4nioX2L70ZUMIFysS3xvBsSG4x/n1V6TXV3N8ZYNuFGlDirFg32T7B6WOUPDYcQ==", + "requires": { + "@babel/runtime": "^7.7.6" + } + }, "hoopy": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/hoopy/-/hoopy-0.1.4.tgz", @@ -25453,6 +25494,23 @@ "resolved": "https://registry.npmjs.org/react-refresh/-/react-refresh-0.11.0.tgz", "integrity": "sha512-F27qZr8uUqwhWZboondsPx8tnC3Ct3SxZA3V5WyEvujRyyNv0VYPhoBg1gZ8/MV5tubQp76Trw8lTv9hzRBa+A==" }, + "react-router": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.2.2.tgz", + "integrity": "sha512-/MbxyLzd7Q7amp4gDOGaYvXwhEojkJD5BtExkuKmj39VEE0m3l/zipf6h2WIB2jyAO0lI6NGETh4RDcktRm4AQ==", + "requires": { + "history": "^5.2.0" + } + }, + "react-router-dom": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.2.2.tgz", + "integrity": "sha512-AtYEsAST7bDD4dLSQHDnk/qxWLJdad5t1HFa1qJyUrCeGgEuCSw0VB/27ARbF9Fi/W5598ujvJOm3ujUCVzuYQ==", + "requires": { + "history": "^5.2.0", + "react-router": "6.2.2" + } + }, "react-scripts": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/react-scripts/-/react-scripts-5.0.0.tgz", diff --git a/package.json b/client/package.json similarity index 95% rename from package.json rename to client/package.json index f065883..59d524c 100644 --- a/package.json +++ b/client/package.json @@ -8,6 +8,7 @@ "@testing-library/user-event": "^13.5.0", "react": "^18.0.0", "react-dom": "^18.0.0", + "react-router-dom": "^6.2.2", "react-scripts": "5.0.0", "web-vitals": "^2.1.4" }, diff --git a/public/favicon.ico b/client/public/favicon.ico similarity index 100% rename from public/favicon.ico rename to client/public/favicon.ico diff --git a/public/index.html b/client/public/index.html similarity index 100% rename from public/index.html rename to client/public/index.html diff --git a/public/logo192.png b/client/public/logo192.png similarity index 100% rename from public/logo192.png rename to client/public/logo192.png diff --git a/public/logo512.png b/client/public/logo512.png similarity index 100% rename from public/logo512.png rename to client/public/logo512.png diff --git a/public/manifest.json b/client/public/manifest.json similarity index 100% rename from public/manifest.json rename to client/public/manifest.json diff --git a/public/robots.txt b/client/public/robots.txt similarity index 100% rename from public/robots.txt rename to client/public/robots.txt diff --git a/src/App.css b/client/src/App.css similarity index 100% rename from src/App.css rename to client/src/App.css diff --git a/client/src/App.js b/client/src/App.js new file mode 100644 index 0000000..93d5281 --- /dev/null +++ b/client/src/App.js @@ -0,0 +1,18 @@ +import './App.css'; +import { Routes, Route, BrowserRouter } from 'react-router-dom'; + +import Welcome from './components/Welcome'; + +function App() { + return ( +
+ + + }/> + + +
+ ); +} + +export default App; diff --git a/src/App.test.js b/client/src/App.test.js similarity index 100% rename from src/App.test.js rename to client/src/App.test.js diff --git a/client/src/components/Welcome.js b/client/src/components/Welcome.js new file mode 100644 index 0000000..2b64060 --- /dev/null +++ b/client/src/components/Welcome.js @@ -0,0 +1,13 @@ +export default function Welcome() { + return ( + <> +

Welcome to Splinter

+

Compete with your friends to have the lowest
possible amount of resources to your name!

+ +

Choose from the options below:

+
+ +
+ + ) +} \ No newline at end of file diff --git a/src/index.css b/client/src/index.css similarity index 100% rename from src/index.css rename to client/src/index.css diff --git a/src/index.js b/client/src/index.js similarity index 100% rename from src/index.js rename to client/src/index.js diff --git a/src/logo.svg b/client/src/logo.svg similarity index 100% rename from src/logo.svg rename to client/src/logo.svg diff --git a/src/reportWebVitals.js b/client/src/reportWebVitals.js similarity index 100% rename from src/reportWebVitals.js rename to client/src/reportWebVitals.js diff --git a/src/setupTests.js b/client/src/setupTests.js similarity index 100% rename from src/setupTests.js rename to client/src/setupTests.js diff --git a/src/App.js b/src/App.js deleted file mode 100644 index 3784575..0000000 --- a/src/App.js +++ /dev/null @@ -1,25 +0,0 @@ -import logo from './logo.svg'; -import './App.css'; - -function App() { - return ( -
-
- logo -

- Edit src/App.js and save to reload. -

- - Learn React - -
-
- ); -} - -export default App;