Description | Requirements | Technologies | Usage | Demonstration
Project developed with the intention of deepening knowledge in websockets with real-time applications and integration with htttp servers.
It consists of a support chat site between customer with question and admin respondent, where admin can choose customer he wants to respond according to priority (based on time of message sent), and close his connection once queries are answered . Anyone can test the application in order to contract the service for their own website by contacting the responsible developer (myself).
The first version of the project was developed at the Next Level Week 5 (NLW) marathon, taught by Daniela Leão, from April 19 to 25, 2021.
- Nodejs
- Typescript
- Express
- Socket.io
- TypeORM
- SqlServer
- ESLint
- Nextjs
- Typescript
- StyledComponents
- Socket.io-client
- ESLint (Airbnb config + pessoal rules)
- Prettier
You can clone it on your pc using the command:
git clone https://github.com/Lissone/lix-attendance.git
cd lix-attendance
Install dependencies using:
yarn
#or
npm install
You must create the database before running an api (dbLixAttendance).
// .\src\external\database\dbConfig.ts
const connection = createConnection({
type: 'mssql',
host: process.env.DB_HOST,
port: 1433,
username: process.env.DB_USERNAME,
password: process.env.DB_PASSWORD,
database: process.env.DB_NAME,
entities: [**Entities**],
synchronize: true,
logging: false,
options: {
enableArithAbort: true
}
})
Need to add environment variables in both projects:
# .\packages\web\.env.local
# DEFAULT
NEXT_PUBLIC_BASE_URL_API=http://localhost:5000
# .\packages\api\.env
# DEFAULT
PORT=5000
DB_USERNAME=sa
DB_PASSWORD=123456
DB_NAME=dbLixAttendance
DB_HOST=localhost
Run api:
cd .\packages\api\
yarn dev
#or
npm run dev
Run web:
cd .\packages\web\
yarn dev
#or
npm run dev
Distributed under the MIT License. See LICENSE
for more information.