Skip to content
Draft
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
48,875 changes: 20,259 additions & 28,616 deletions client/package-lock.json

Large diffs are not rendered by default.

6 changes: 4 additions & 2 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,15 @@
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/user-event": "^13.5.0",
"express": "^4.18.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-scripts": "^2.1.3",
"react-scripts": "5.0.1",
"react-static-google-map": "^0.9.0",
"web-vitals": "^2.1.4"
},
"scripts": {
"start": "react-scripts --openssl-legacy-provider start",
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
Expand Down
21 changes: 21 additions & 0 deletions client/src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,24 @@
transform: rotate(360deg);
}
}

.my-form{
color: #61dafb;
}
/* #wrap {
width: 750px;
height: 1500px;
padding: 0;
overflow: hidden;
} */

.scaled-frame {
width: 750px;
height: 1500px;
padding: 0;
overflow: hidden;
/* width: 1000%;
height: 1000%;
border: 100px; */
}

62 changes: 38 additions & 24 deletions client/src/App.js
Original file line number Diff line number Diff line change
@@ -1,29 +1,43 @@
import logo from './logo.svg';
import React from "react";
import './App.css';
import React, { useEffect, useState } from "react";

function App() {
const [data, setData] = React.useState(null);

React.useEffect(() => {
fetch("/api")
.then((res) => res.json())
.then((data) => setData(data.message));
}, []);

return (
<div className="App">
<header className="App-header">
<p>Plannect!!</p>
<p>this is our website</p>
<img src={logo} className="App-logo" alt="logo" />
<p>
{!data ? "Loading...": data}
</p>

</header>
</div>
function App() {

const [user, setUser] = useState([]);


const fetchAutoCodeData= async() => {
return await fetch("https://riyapatel.api.stdlib.com/plannect@dev/")
.then((response) => response.json())
.then((data) => setUser(data));

}

useEffect(() => {
fetchAutoCodeData();

},[])

return (

<main>
<p>Welcome To Plannect</p>

<iframe
src="https://jpywnvxt6c4.typeform.com/to/i7hFvACI"
></iframe>

<p>
Similar Interests:
{user.choices[0].text}
</p>
<p>Find People Near You:</p>
<img src="https://api.mapbox.com/styles/v1/mapbox/navigation-night-v1/static/-79.467728,43.771912,13,0,60/1200x500?access_token=pk.eyJ1Ijoicml5YXBwMjUiLCJhIjoiY2wyd2s0MnViMG1kbTNsbXZxdmdwd2RiaCJ9.OiS4eMrR0nGsrj_oaKVdmQ"></img>

</main>
);
}

}
export default App;


1 change: 1 addition & 0 deletions client/src/index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

import React from 'react';
import ReactDOM from 'react-dom/client';
import './index.css';
Expand Down
102 changes: 102 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
},
"homepage": "https://github.com/riyapatel25/plannect#readme",
"dependencies": {
"@typeform/embed-react": "^2.15.0",
"express": "^4.18.2",
"prettier": "^2.8.4"
}
Expand Down
33 changes: 24 additions & 9 deletions server/index.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,26 @@

const express = require("express");
const PORT = process.env.PORT || 3000;
const app = express();

app.get("/api",(req, res) =>{
res.json({message: "PLANNECT!"});
});
app.listen(PORT, () => {
console.log("server listening")
import Express from 'express'

const app = Express();

import userRoutes from "./users"

app.use("/api/users", userRoutes)


app.listen(3000, () =>{
console.log('working!')
})



// / const express = require("express");
// const PORT = process.env.PORT || 3000;
// const app = express();

// app.get("/api",(req, res) =>{
// res.json({message: "PLANNECT!"});
// });
// app.listen(PORT, () => {
// console.log("server listening")
// })
14 changes: 14 additions & 0 deletions server/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"name": "server",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"start": "node index.js"
},
"keywords": [],
"author": "",
"license": "ISC",
"type": "module"
}
10 changes: 10 additions & 0 deletions server/routes/users.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import express from 'express'

const router = express.Router()


router.get("/test",(req, res) =>{
res.send("yay it works!")
})

export default router